From: joerg van den hoff <j.van_den_hoff_at_fz-rossendorf.de>

Date: Tue 11 Oct 2005 - 01:47:11 EST

n = "b"

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Tue Oct 11 02:12:10 2005

Date: Tue 11 Oct 2005 - 01:47:11 EST

print (lapply(x, subset, select = a)) ### works print (lapply(x, subset, select = "a")) ### works print (lapply(x, subset, select = n)) ### does not work as intended}

n = "b"

tt("a") #works (but selects not the intended column) rm(n) tt("a") #no longer works in the lapply call including variable 'n'

question: how can I enforce evaluation of the variable n such that the lapply call works? I suspect it has something to do with eval and specifying the correct evaluation frame, but how? ....

many thanks

joerg

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Tue Oct 11 02:12:10 2005

*
This archive was generated by hypermail 2.1.8
: Fri 03 Mar 2006 - 03:40:41 EST
*