Possible Duplicate:
how to get value when a variable name is passed as a string
So I’m using assign() to create a variable
nam <- "act01"
assign(nam, read.table(text.txt, sep = ", ", header = T))
and I’m trying to append the act01 variable just created into another list
acts = list()
acts[[1]] <- nam # something wrong here, I can't find a way to retrieve the variable
Is there any function that allows you to convert the string into a variable in R?
Thanks alot
Too much work; just write
or better
where
text.txtsis a vector of your files, made for instance bylist.files().