[R] extract column's from different dataframe

2013-10-17 Thread catalin roibu
Dear R users,

I want to extract column's from different data frame with different row
length.
How can I do this in R?

Thank you very much!

best regards!

CR

-- 
---
Catalin-Constantin ROIBU
Lecturer PhD, Forestry engineer
Forestry Faculty of Suceava
Str. Universitatii no. 13, Suceava, 720229, Romania
office phone +4 0230 52 29 78, ext. 531
mobile phone   +4 0745 53 18 01
   +4 0766 71 76 58
FAX:+4 0230 52 16 64
silvic.usv.ro

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


Re: [R] extract column's from different dataframe

2013-10-17 Thread Jim Lemon

On 10/17/2013 06:17 PM, catalin roibu wrote:

Dear R users,

I want to extract column's from different data frame with different row
length.
How can I do this in R?


Hi catalin,
If I understand your question, which I think is:

I want to extract columns from different data frames with differing 
numbers of rows and store them in a single object.


The answer is probably to use a list:

datalist-list()
datalist[[1]]-dataframe1[,variable1]
datalist[[2]]-dataframe2[,variable3]
...

where each element of datalist may have different numbers of values.

Jim

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.