[R] simple problem with unquoting argument

Troels Ring tr|ng @end|ng |rom gvdnet@dk
Wed Jul 3 10:13:59 CEST 2024


Hi  friends - I'm in problems finding out how to unquote - I have a 
series of vectors named adds1....adds11 and need to e.g. find the sum of 
each of them

So I try

SS <- c()

for (i in 1:11) {

e <- paste("adds",i,sep="")

SS[i]  <- sum(xx(e)) }

Now e looks right - but I have been unable to find out how to get the 
string e converted to the proper argument for sum()  - i.e. what  is 
function xx?

All best wishes
Troels Ring, Aalborg, Denmark



More information about the R-help mailing list