Hi
I have a list which cosists out of dataframes of the same structure. Now I
want to extract one column (let's say column A) from all dataframes and
have them in a matrix (or dataframe).
At the moment I am doiong:
d - data.frame(A=runif(100), B=rnorm(100))
theList - list(e1=d, e2=d, e3=d,
Try this:
sapply(theList, '[[', 'A')
On Wed, Sep 16, 2009 at 8:34 AM, Rainer M Krug r.m.k...@gmail.com wrote:
Hi
I have a list which cosists out of dataframes of the same structure. Now I
want to extract one column (let's say column A) from all dataframes and
have them in a matrix (or
On Wed, Sep 16, 2009 at 1:35 PM, Henrique Dallazuanna www...@gmail.comwrote:
Try this:
sapply(theList, '[[', 'A')
Thanks Henrique - that is much more elegant.
Rainer
On Wed, Sep 16, 2009 at 8:34 AM, Rainer M Krug r.m.k...@gmail.com wrote:
Hi
I have a list which cosists out of
3 matches
Mail list logo