[R] Changing data frame column headings
arun
smartpink111 at yahoo.com
Wed Dec 5 22:43:51 CET 2012
Hi Rich,
You can get ?rename() by either loading library(reshape) or library(plyr).
A.K.
----- Original Message -----
From: Rich Shepard <rshepard at appl-ecosys.com>
To: R help <r-help at r-project.org>
Cc:
Sent: Wednesday, December 5, 2012 4:24 PM
Subject: Re: [R] Changing data frame column headings
On Wed, 5 Dec 2012, arun wrote:
> I am not sure why ?rename() is not working.
> a <- list(a = 1, b = 2, c = 3)
> rename(a, c(b = "a", c = "b", a="c"))
I have the reshape2 library loaded and ?rename did not find the help page.
Are the parentheses required in the command?
Thanks,
Rich
______________________________________________
R-help at 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.
More information about the R-help
mailing list