Skip to content
Prev 207974 / 398502 Next

Explanation w.r.t. rbind, please!

What you (probably) want here is
num.mat ["seq",]
num.mat["num.vec",]

and so on. You have to use tell R that you want the ROW (that's why the
comma is needed) defined by the NAME "seq" or "num.vec" (that's why you
need "") . Otherwise, R replaces seq by its value 1:4, so 
num.mat[seq] 
is identical to 
num.mat[1:4] 
(and num.mat[12.34] is NA of course in num.mat[num.vec])

You should have a closer look at ?Extract
HTH, Michael