Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: mi passive - When is it executed?

From   Richard Williams <>
To, "" <>
Subject   Re: st: mi passive - When is it executed?
Date   Mon, 11 Jun 2012 22:04:42 -0500

At 05:31 PM 6/11/2012, Isaac Knowles wrote:
Hi, Statalisters,

I am wondering when, during the imputation step, Stata actually generates a passive variable. I am currently using Stata 12's "mi impute chained" to execute imputation of about 8 different variables, including age and earnings. I want to use a quartic in age when imputing earnings. Both age and earnings are missing, but by far earnings is missing more. The missing pattern is not monotone. In both the burn-in and imputation steps, I want Stata to first impute the value of age where it is missing (which it does automaticall). Then I want it to generate the age quartic based on the imputed values. Finally, I want it to use the age quartic to impute log earnings (which it also does, but I'm not sure if the quartic is using the latest imputed values) It's not clear to me from reading the manual that Stata is smart enough to know when I want these things calculated, though. So does anyone know when a passive variable is generated during the imputation
 process? Is it doing it before it imputes earnings? Or at the very end?

A much-abbreviated version of the code I have a question about goes as follows:

mi set wide
mi register: ageimp lnearnimp
mi passive: gen age2imp = ageimp*ageimp
mi passive: gen age3imp = age2imp*ageimp
mi passive: gen age4imp = age3imp*ageimp
mi impute chained (reg) ageimp (reg, include(age2imp age3imp age4imp) lnearnimp, [some options here] add(10)

FYI, Paul Allison and others argue against passive imputation. They argue that you should do things like compute x^2 first, and then impute its missing values. That seems counterintuitive but Allison claims it works best. See

As for ordering, I would think that the -mi passive- commands would come after the -mi impute chained- command.

Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME:   (574)289-5227
EMAIL:  Richard.A.Williams.5@ND.Edu

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index