Reputation: 141
I am attempting to rename values within my data frame "meansleep"
I have columns "Id" within the Id columns I have 22 values and I am attempting to rename these values to "sleepy1", "sleepy2", "sleepy3", ...
I am using function meansleep$Id\[c(1:22)\] \<- c('sleepy1', 'sleepy2', ...)
Is there a way to run this function without retyping all the sleepyvalues.. for instance to correlate c(1:22)
to c('sleepy1':'sleepy22')
Thank you
Upvotes: 1
Views: 268