Hello
I'm currently doing a register-based cohort study on maternal smoking during pregnancy and the risks of cryptorchidism and hypospadias (two male genital malformations).
During my study period, hospitals changes their registries on patients smoking habits from never/former/current to categorizing in number of cigarettes per day.
I created a variable for the whole period smoke_tot but I also wish to look into a dose-response pattern with the latter variable smoke_cat.
smoke_cat consists of the following categories:
0: Never smoked during pregnancy
1: Stopped smoking during pregnancy
2: Smoked <=5cigarettes per day during pregnancy
3: 6-10 cig/day
4: 11-20 cig/day
5: >=21cig/day
6: Smoked during pregnancy, amount unknown
.: Missing
I have 7 dependent variables and 4 independent variables.
My STATA syntax is the following
mi set mlong
mi register imputed smoke_tot smoke_cat gest_age birthweight parity education_year nationality marriage
mi impute chained (ologit) smoke_tot smoke_cat education_year (mlogit) nationality (regress) gest_age birthweight = birthyear_grp matage cryptorchidism hypospadias
So my problems are the following:
I wish to use multiple imputation on both categories, but smoke_cat does not cover the whole study period and it has a missing values, which needs to be imputated over all categories + a category 6, which needs to be imputated only over category 2-5.
I also need to restrict imputations for smoke_cat to birthyear>1996
I hope you can help
Related Posts with Multiple imputation on selected categories within a variable
bootstrap: insufficient observations to compute bootstrap standard errorsI don't know the exact reason. Can anyone help me out? Here is the data and code: Code: * Example …
Irregular gaps between bars on graph barDear Statalisters I ran into a strange problem when making a bar graph. I have a lot of categories …
Identification of gender from names through machine learning methodsHi, Code: * Example generated by -dataex-. To install: ssc install dataex clear input str37 name …
dropping constant in a fixed effects modelDear Statalist members, I just wanted to check if there is a way I can specify a fixed effects mode…
the smae code and the same data, but the result is different using STATA 13,15 and 16In Stata 16, the code below cannot run normally, but in Stata 15 and Stata 13, the code can run corr…
Subscribe to:
Post Comments (Atom)
0 Response to Multiple imputation on selected categories within a variable
Post a Comment