I am trying to run various regressions based on multiply imputed data, and would like to preserve the same sample size as in my original regression. Normally, I would use "keep if e(sample)," but I am receiving error messages that this will not work with imputed data.
Anyone know how to amend this code? Note, my code here has been amended so that it will be exported to Latex (that is the "cmdok post:" part of the code, if you don't recognise that). Thanks!
Code:
mi set mlong mi register imputed migration primary open mi impute chained (regress) migration primary open = hiv aidpercap gdpcap telinfrastructure democracy autocracy unemployment , add(50) rseed (1234) force mi estimate, cmdok post: xtivreg gold time open gdpcap telinfrastructure democracy autocracy unemployment primary migcap (hiv = aidpercap) , fe vce(robust) ..... and then I want to keep this same sample size from line 4 as I go on to do other regressions
0 Response to Preserving sample size across multiple imputation regressions
Post a Comment