[R] name of object in quotes
Gonzalo Rivero
grivero at ceacs.march.es
Wed May 23 12:14:23 CEST 2007
I am writing a function in which, at some point, I to recuperate the
name of a previous object in quotes. I am currently using the function
Cs() from the Hmisc library but the result is:
foo <- function(xvar) {
variable <- Cs(xvar)
return(variable)
}
foo(x1)
> "xvar"
when I would expected to obtain "x1".
Any suggestion?
Thanks
--
*Gonzalo Rivero*
Ph.D. candidate
Centro de Estudios Avanzados en Ciencias Sociales
Juan March Institute
Castelló 77, 2nd floor
28006, Madrid
More information about the R-help
mailing list