[R] svydesign syntax
R user
capanum at mskcc.org
Thu Jul 22 16:46:36 CEST 2010
This message is for those familiar with the survey package. I need to fit a
weighted Cox model to accommodate the sampling weights as I have a
case-control study with controls sampled at random from a database in a
ratio 2:1 to cases (whom were all sampled). I want to make sure I am using
the right svydesign syntax to specify this sampling design. Can anyone
please check if the statement below is appropriate for my design?
#group represents the case (total of 132) vs control (253 out of the total
of 853 controls) groups; prob is 1 for cases and 253/853 for controls and
ssize=132 for cases and 853 otherwise;
dstr=svydesign(id=~1, strata=~group, prob=~prob, fpc=~ssize, data=noNA)
--
View this message in context: http://r.789695.n4.nabble.com/svydesign-syntax-tp2298793p2298793.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list