[R] access objects by name

2011-06-20 Thread Noah Silverman
Hi, I have several data structures (xts structures). I then have a list of the names of those objects. I'd like to access the object by name. For example: foo1 - as.xts() foo2 - as.xts(...) foo3 - as.xts(...) structs - c(foo1, foo2, foo3) for (thisOne in structs){

Re: [R] access objects by name

2011-06-20 Thread jim holtman
for (thisOne in structs){ print(get(thisOne)$colA) } you need to 'get' (retrieve) the object first. On Mon, Jun 20, 2011 at 5:18 PM, Noah Silverman noahsilver...@ucla.edu wrote: Hi, I have several data structures (xts structures).  I then have a list of the names of those objects. I'd