On Nov 16, 2010, at 10:34 AM, Kevin Ummel wrote:
A bit embarrassed to post this seemingly trivial question, but I
can't find anything in the archive that's quite relevant:
a1=1
a2=2
obs=objects(pattern=glob2rx("a?"))
I want to utilize 'obs' as a function argument to produce something
like:
sum(a1,a2)
?get
> sum(sapply(obs, get))
[1] 3
Obviously, sum(obs) doesn't work, but I've tried variations of
'eval', 'parse', 'mget', and 'noquote' without success. What am I
missing?
Thanks,
Kevin
--
David Winsemius, MD
West Hartford, CT
______________________________________________
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.