Skip to content
Prev 181204 / 398502 Next

Behavior of seq with vector from

Brilliant! Thanks, Brian

-----Original Message-----
From: Gabor Grothendieck [mailto:ggrothendieck at gmail.com] 
Sent: Friday, May 22, 2009 11:20 AM
To: Rowe, Brian Lee Yung (Portfolio Analytics)
Cc: Peter Dalgaard; r-help at r-project.org
Subject: Re: [R] Behavior of seq with vector from


Try it this way:

# test list of data frames
L <- list(anscombe[1:4], anscombe[5:8], anscombe[1:4], anscombe[5:8])

# get columns 2 and 3 from each component; cbind those together
do.call(cbind, lapply(L, "[", 2:3))


On Fri, May 22, 2009 at 11:01 AM, Rowe, Brian Lee Yung (Portfolio
Analytics) <B_Rowe at ml.com> wrote: