Hi all,
I am working with nine waves of a large, nationally-representative cross-sectional dataset with information on multiple dimensions of population health and determinants (NHANES). I chose to conduct multiple imputation to preserve observations with missing information on some covariates. Now that I have completed this, I am having issues running the commands to complete my descriptive table.
For example, my dataset includes five racial/ethnic subpopulations, and I would like to obtain proportions (and ideally observation counts for each cell, along with a chi-square stat for difference) on all of the covariates across these five subpopulations.
I am attempting to do so in the following way with:
mi estimate: svy, subpop(if studypops2==1): proportion age_cat
mi estimate: svy, subpop(if studypops2==2): proportion age_cat
mi estimate: svy, subpop(if studypops2==3): proportion age_cat
mi estimate: svy, subpop(if studypops2==4): proportion age_cat
mi estimate: svy, subpop(if studypops2==5): proportion age_cat
I am running into some issues with this: 1) there is no option to obtain the number of observations, 2) there is no option to obtain a chi-square stat for difference. These issues, while inconvenient, are not as pressing as the fact that the number of observations in the population is changing depending on which subpop I am focusing on. The note given by Stata was:
"Note: 26 strata omitted because they contain no subpopulation members."
Does anyone know of 1) a better way to execute the descriptive statistics with svy data that has been multiply imputed? Or, 2) any tweaks to make my current approach work better/prevent strata from being omitted?
Many thanks,
Maria
I am working with nine waves of a large, nationally-representative cross-sectional dataset with information on multiple dimensions of population health and determinants (NHANES). I chose to conduct multiple imputation to preserve observations with missing information on some covariates. Now that I have completed this, I am having issues running the commands to complete my descriptive table.
For example, my dataset includes five racial/ethnic subpopulations, and I would like to obtain proportions (and ideally observation counts for each cell, along with a chi-square stat for difference) on all of the covariates across these five subpopulations.
I am attempting to do so in the following way with:
mi estimate: svy, subpop(if studypops2==1): proportion age_cat
mi estimate: svy, subpop(if studypops2==2): proportion age_cat
mi estimate: svy, subpop(if studypops2==3): proportion age_cat
mi estimate: svy, subpop(if studypops2==4): proportion age_cat
mi estimate: svy, subpop(if studypops2==5): proportion age_cat
I am running into some issues with this: 1) there is no option to obtain the number of observations, 2) there is no option to obtain a chi-square stat for difference. These issues, while inconvenient, are not as pressing as the fact that the number of observations in the population is changing depending on which subpop I am focusing on. The note given by Stata was:
"Note: 26 strata omitted because they contain no subpopulation members."
Does anyone know of 1) a better way to execute the descriptive statistics with svy data that has been multiply imputed? Or, 2) any tweaks to make my current approach work better/prevent strata from being omitted?
Many thanks,
Maria
Comment