[R] binding data.frames with sequential names
Anthony Fristachi
antaknee at gmail.com
Tue Dec 14 01:02:36 CET 2010
Hello,
I have data frames X1 to X19
I want a simple way to bind them as the next run(s) will generate many
more sequential data frames.
I tried the following with i = 19:
> my.list <- as.list(paste("X",1:i,sep=""))
> new.data <- do.call("rbind", my.list)
> new.data
[,1]
[1,] "X1"
[2,] "X2"
[3,] "X3"
[4,] "X4"
[5,] "X5"
[6,] "X6"
[7,] "X7"
[8,] "X8"
[9,] "X9"
[10,] "X10"
[11,] "X11"
[12,] "X12"
[13,] "X13"
[14,] "X14"
[15,] "X15"
[16,] "X16"
[17,] "X17"
[18,] "X18"
[19,] "X19"
Thank you
Tony
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Tony Fristachi
Human Health and Ecological Risk Assessor
Portage, Inc.
335 Central Park Square
Los Alamos, NM 87544
office: 505.663.1526 / fax: 505.662.7340
cell: 505.412.8442
www.portageinc.com
More information about the R-help
mailing list