[R] renaming objects

Ericka Lundström e at it.dk
Mon Mar 3 22:38:34 CET 2008


On 03/03/2008, at 22.20, Giles.Crane at doh.state.nj.us wrote:
> Is there a way to rename R objects?
> I am looking for a way to rename objects
> without making new objects.
>
> #For example:
> x = c(1:40)
> # I wish to use a function to rename x, already created, to y,  
> perhaps by
> obj.rename(x,y)
> # or
> obj.rename("x","y")
y <- x # changes x to y with same values.

Ericka



More information about the R-help mailing list