data(api)
dclus2<-svydesign(id=~dnum+snum, fpc=~fpc1+fpc2, data=apiclus2)
tt<-svyttest(enroll~comp.imp, dclus2)
tt
confint(tt, level=0.9)
svyttest(enroll~I(stype=="E"),dclus2)
svyttest(I(api00-api99)~0, dclus2)
Run the code above in your browser using DataLab