R noob here..  I have the following data frame  >data   Value Multiplier1  15    H2   0    h3   2    +4   2    ?5   2    kwhere the multiplier is of class factor. The values of K & k is 3, + is 5 and ? is 2.  I have used > data$Multiplier <-  revalue(data$Multiplier, c(+=5))> data$Multiplier <-  revalue(data$Multiplier, c(?=2))> data$Multiplier <-  revalue(data$Multiplier, c(K=3))> data$Multiplier <-  revalue(data$Multiplier, c(k=3))  Is there a better way of doing it?
R: Revalue multiple special characters in a data.frame
r;data cleaning
That seems pretty straight forward to me. I'm pretty new too but in general I'm not sure if you can get better than one command. Though you could have combined all that:> newValueVector <- c(+=5, ?=2, K=3, k=3)> data$Multiplier <-  revalue(data$Multiplier, newValueVector)