search for: ces08_hhwgt

Displaying 1 result from an estimated 1 matches for "ces08_hhwgt".

2011 Mar 30
1
sampling design runs with no errors but returns empty data set
...TWGT)) weight_test<-svydesign(id=~0, weights=~ces08_NATWGT, data=missing_data) Note: this is some reproducible code that creates a data set that is a very stripped down version of what I'm working with, but with this, the surveydesign function appears to work properly. mydat<-data.frame(ces08_HHWGT=runif(3000, 0.5, 5), ces08_PROVWGT=runif(3000, 0.6, 1.2), party=sample(c("NDP", "BQ", "Lib", "Con"), 3000, replace=TRUE), age=sample(seq(18, 72,1), 3000, replace=TRUE), income=sample(seq(21,121,1), 3000, replace=TRUE)) mydat$ces08_NATWGT<-mydat$ces08_HHWGT...