search for: miset1

Displaying 2 results from an estimated 2 matches for "miset1".

2008 May 28
1
manipulating multiply imputed data sets
...using MIM, but I've decided to go cold turkey on other stats packages as a incentive for learning more about R. Most of the recoding is for nominal variables, like race, religion, urbanicity, and the like. So, for example, to recode race for my first dataset, inmi1, I would do the following: miset1$white <- recode(miset1$RACE, '1=1; else=0; ') miset1$black <- recode(miset1$RACE, '2=1; else=0; ') miset1$asian <- recode(miset1$RACE, '3=1; else=0; ') miset1$hispanic <- recode(miset1$RACE, '4=1; else=0; ') miset1$raceother <- recode(miset1$RACE, &...
2009 Oct 17
2
repeating values in levels()
Can someone help me understand this results? > levels(as.factor(miset1$facts_convict)) [1] "1" "1" "2" "3" "4" "5" "6" converting to numeric and back doesn't seem to help: > levels(as.factor(as.numeric(miset1$facts_convict))) [1] "1" "1" "2" "3" &quot...