[R] using for variable as rowname

Ralikwen Balazs.Klein at gmail.com
Wed Sep 17 16:22:11 CEST 2008


Is there a way to use the cycle variable for rowname?

v=1:6
for (a in 1:3){
 for  (b in 4:5) {
  v=rbind(v,a.b=1)
 }
}
v

This above obviously does not work, but I couldn't find out how to use a and
b to construct a rowname like 14, 15, 24, 25.
Thanks for the help.
Balazs
-- 
View this message in context: http://www.nabble.com/using-for-variable-as-rowname-tp19533203p19533203.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list