Hi, I'm using inverse probability treatment weighting for the propensity for vaccination, followed by Cox regression. My exposure is vaccination and my outcome is death in the first week of life. Can I add a random effect term for mothers who have had more than one birth (and subsequent death in the first week)?
thanks
Minda
logistic fluvac ///
i.matage5y i.mum_abor parity i.anctrimester i.year_season_birth ///
i.smoke i.seifa10 i.asthma i.hypertension i.diabetes i.gestdiabetes i.gesthypertension i.preeclampsia
predict p
gen ipw=.
replace ipw=1/p if fluvac_com==1
replace ipw=1/(1-p) if fluvac_com==0
** Unweighted
stset endrisk_firstweek, origin(origin_firstweek) enter(startrisk_firstweek) exit(time .) ///
fail(died==1) id(babyid) scale(365.25)
stcox i.fluvac, vce(robust)
stset, clear
** Weighted
stset endrisk_firstweek [pweight=ipw], origin(origin_firstweek) enter(startrisk_firstweek) exit(time .) ///
fail(died=1) id(babyid) scale(365.25)
stcox i.fluvac, vce(robust)
stset, clear
Related Posts with Random effects term for mother - help with some code
Pseudo R2HI, I'd be grateful if you could help me clarify this please. I have performed 2 mutlivariate logsi…
msymbolI'm quite new to state. I wanted to make the graph I created (which I'm also not sure of if its corr…
System-gmm xtabond2 - Correct specifications of additional lags of a regressor in the instrument set?Dear statalist users, I am using xtabond2 in Stata 13.1 to estimate the effects of police inspectio…
Match value labels from two different datasetsDear Statalisters I have two different datasets with information on States and Districts. Since the…
How to test *coefficient estimates across samples using the same model?Dear All, I have the below models. I run the same model in two different samples (firms which have …
Subscribe to:
Post Comments (Atom)
0 Response to Random effects term for mother - help with some code
Post a Comment