most all those posts were right in sourcing the problem....its just that nobody actually offered a viable solution
the problem is that the new level "C" was not one of the original levels in $social status add "C" as a level and then just do the ol fashioned way and it works just fine do this: data$SOCIAL_STATUS <- factor(data$SOCIAL_STATUS, levels = c(levels(data$SOCIAL_STATUS), "C")) then this: data$SOCIAL_STATUS<-ifelse(data$SOCIAL_STATUS=="B" & data$MALE>4, "C", data$SOCIAL_STATUS) it is sooo much more helpful when someone who has addressed the specific problem being asked replies instead of people just throwing random ideas out there -- View this message in context: http://r.789695.n4.nabble.com/How-to-avoid-ifelse-statement-converting-factor-to-character-tp895726p3992067.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@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.