lundi 23 mars 2015

Find and replace many factors in one column in R

I have column with 32 different levels. I need to replace these levels



?
diet
diet contr
IDDM
Note
Other
denial
Resolved
Unsure


in that column to No


I know I can do this using a massive ifelse((column = "?" | column = "diet" |.....) statement, i was wondering if there is an efficient way to do replace these bag of factors ?


Aucun commentaire:

Enregistrer un commentaire