jour4life
2012-Apr-15 23:36 UTC
[R] correct standard errors (heteroskedasticity) using survey design
Hello all, I'm hoping someone can help clarify how the survey design method works in R. I currently have a data set that utilized a complex survey design. The only thing is that only the weight is provided. Thus, I constructed my survey design as: svdes<-svydesign(id=~1, weights=~weightvar, data=dataset) Then, I want to run an OLS model, so: fitsurv<-svyglm(y~x1+x2+x3...xk, design=svdes, data=dataset) But, I want to check if there is evidence of heteroskedasticity. If so, how would I correct the standard errors? Can the "sandwich" library do this? Are the standard errors already adjusted. How else can I verify if heteroskedasticity is still present? Can I still use the bptest()? I read an earlier post where someone used a dataset example entitled "banco." But, her dataset included strata and cluster variables. Someone responded that the "sandwich" library already adjusted for clustering. In my situation, however, I only have a weight variable. I hope someone can clarify this problem for me. Thanks, Carlos -- View this message in context: http://r.789695.n4.nabble.com/correct-standard-errors-heteroskedasticity-using-survey-design-tp4560122p4560122.html Sent from the R help mailing list archive at Nabble.com.