# Using heckman in combination with mi estimate (Stata)

This is a Stata specific question, and may be better directed to Stata's own Statalist, but I'm trying here first.

Here is the situation. I have a multiply-imputed data set, where the number of imputations = 10 and where imputations are only performed on independent variables. I would like to run the heckman command on these data, using the mi estimate prefix. The heckman command is not a "supported command", but it is possible to force estimation using the cmdok option. My questions are these: Why isn't heckman a supported command? Are the results that I get when I force Stata to fit the model (using the cmdok option) valid? Or, is there some statistical reason why a Heckman-style selection procedure should not be used in a multiply-imputed data setting?

I haven't used the mi command yet but I am using the user-written command mim in Stata for multiple imputed dataset. There are basically two issues in regard to your question. First, Rubin's method can be still used for the regression coefficients in the Heckman model as being used for linear regression. Second, marginal effects can be still combined as per Rubin's method as is mentioned here. As to why one need to invoke cmdok, Yulia Marchenko provides the following reasons (details here in Statalist)

Commands are officially supported by mi estimate if they

1) produce the numerical results that mi estimate needs and stores them where mi estimate expects (explained below)

2) work properly with available mi estimate postestimation tools, and

3) produce good-looking mi estimate output.

Barry, I don't think there are any issues. MI is more traditionally used in medical and other social sciences than in economics, where the tradition is to make as few model assumptions as possible as possible, so as to make inference as robust to potential violations of these assumptions. So economists don't use it as much, as Stata did not invest much time testing how mi works with heckman.

As a technical matter, there are transformed coefficients that heckman reports as rho, the correlation between the residuals in the two regressions. They are parameterized and internally estimated with an arctanh transformation, so mi estimate will report the transformed correlation, which you would need to translate back if you need to using an appropriate nlcom.

• Fisher transformation is atanh, nor arctan. – Nick Cox Jul 29 '13 at 21:43