• Data types
• operators
,Data Types
, Data Types
Vector:
• A Vector is a sequence of data elements of the same basic ty
Example 1:
• vtr = c(1, 3, 5 ,7 9) or vtr <- c (1, 3, 5 ,7 9)
• print(vtr)
• o/p: [1] 1 3 5 7 9
• creating sequence vector by using colon operator:- v = 3.
• using seq() (sequence) function, create vector from 1 to 9
increment by 2.
• a=seq(1,10,by=2)
• a o/p: [1] 1 3 5 7 9