Displaying 1 result from an estimated 1 matches for "whichsurvey".
2009 Nov 13
1
spss imports--trouble with to.data.frame
...n)
d2 <- read.spss("ESS3e03_2.por",to.data.frame=T)
d2 <- read.spss("ESS3e03_2.por")
warnings()
### You can try to go into a data frame in one
### step, that's an option in read.spss. But
### we saw warnings, and wanted to be careful.
d2 <- as.data.frame(d2)
d2$whichSurvey <- 2
d3 <- read.spss("ESS2e03_1.por")
d3 <- as.data.frame(d3)
d3$whichSurvey <- 3
namesd2 <- names(d2)
namesd3 <- names(d3)
commonNames <- intersect( namesd3, namesd2)
combod23 <- rbind(d2[ , commonNames], d3[, commonNames])
save(combod23, file="combod23...