Working with Vectors :
> x<- c(1,2,3) > x [1] 1 2 3 > x[2] [1] 2 > y<- c(x,4) > y [1] 1 2 3 4 > y[5] [1] NA > y[-c(2:3)] # [ Excludes 2nd and 3rd value of y] [1] 1 4
Back to Index page