[R] Query about substituting characters in a df

lalitha viswanath lalithaviswanath at yahoo.com
Mon Mar 12 20:47:46 CET 2007


Hi
I have a data frame with 40,000 rows and 4 columns,
one of which is "class".


For each row, the "class" column can be one of 10
possible NUMERIC values.
I wish to substitute these numeric values with
words/characters.
For example, I wish to substitute all occurences of
"5467" in the column "class" with "alpha", "7867" with
"gamma", etc.
I looked up substitute, but did not find any relevant
examples.

Your input is greatly appreciated
Thanks
Lalitha


 
____________________________________________________________________________________
Never miss an email again!



More information about the R-help mailing list