Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, is already up and running.

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

st: RE: partialling out exogenous singleton fixed effects in iv-model (ivreg, ivregress)

From   "Schaffer, Mark E" <>
To   "" <>
Subject   st: RE: partialling out exogenous singleton fixed effects in iv-model (ivreg, ivregress)
Date   Mon, 1 Apr 2013 21:08:09 +0000


See comments below.

> -----Original Message-----
> From: [mailto:owner-
>] On Behalf Of
> Sent: 30 March 2013 02:38
> To:
> Subject: st: partialling out exogenous singleton fixed effects in iv-model
> (ivreg, ivregress)
> Hi statlisters,
> Some background:
> I am currently working on an IV model. The model is estimating the effect of
> access to microfinance (instrumented by distance to
> provider) on various outcome variables of interest (income etc.). So for the
> sack of an example suppose we have
> * 1st stage: take-up = b1 + b2*distancetoprovider + i.fe + e
> * 2nd stage: income = a1 + a2*predicted take-up + i.fe + e whereas i.fe are
> my raster fixed effects.
> I included raster fixed effects (whereas rasters are x^2 meters areas) into
> the model in order to ensure the exogeneity of the instrument. It is
> unavoidable that with the raster sizes I would like to use (in order to
> minimize endogeneity) I'll get a few singleton dummies, i.e., a variable with
> one 1 and N-1 zeros.
> Problem #1: So originally I used the -ivreg- command (as it easily tied into a
> program I wrote that produced stacked LaTeX tables). This command gave
> me an error message because I included singleton dummies (through the
> fixed effects) while requesting a robust covariance matrix. The error
> message further said I should try the -partial- option which I then did. Here
> the message:
> Warning: estimated covariance matrix of moment conditions not of full rank.
>          standard errors and model tests should be interpreted with caution.
> Possible causes:
>          singleton dummy variable (dummy with one 1 and N-1 0s or vice
> versa) partial option may address problem

You aren't using ivreg - this is the output of ivreg2, a user-written program (I am the co-author).

Unlike official ivreg (which, as you note below, is now an out-of-date command), we still maintain and upgrade ivreg2 and and you can continue use it.

More below...

> Here is a description of what the partial option is:
> The partial(varlist) option requests that the exogenous regressors in varlist
> are "partialled out" from all the other variables (other regressors and
> excluded instruments) in the estimation.  If the equation includes a constant,
> it is also automatically partialled out as well.  The coefficients corresponding
> to the regressors in varlist are not calculated. [...] A similar problem arises
> when the regressors include a variable that is a singleton dummy, i.e., a
> variable with one 1 and N-1 zeros or vice versa, if a robust covariance matrix
> is requested.  The singleton dummy causes the robust covariance matrix
> estimator to be less than full rank.  In this case, partialling-out the variable
> with the singleton dummy solves the problem.
> Question #1: I don't fully understand what happens when variables are
> "partialled out" and I couldn't find much literature on it. Could somebody
> point me to relevant resources on this?

This is the Frisch-Waugh-Lovell theorem, which is discussed in most econometrics textbooks and various other places as well (including, dare I say it, Wikipedia).

> Is it even legit to use it in a standard
> 2sls model?

Dave Giles has a nice albeit rather advanced discussion on his blog of the FWL theorem and its application to IV:

and mentions in passing that he published a paper in 1984 showing that the FWL theorem applies to IV as well.  The reference is: Giles, D. E. (1984). Instrumental variables regressions involving seasonal data. Economics Letters, 14, 339-343.

> The description of the options mentions how "by the Frisch-
> Waugh-Lovell (FWL) theorem, in IV, two-step GMM and LIML estimation the
> coefficients for the remaining regressors are the same as those that would
> be obtained if the variables were not partialled out."  Does this hold for 2sls
> as well?

For linear models, 2SLS is the same thing as IV.

> More generally speaking, do you think it is okay for me to do this here? What
> are the consequences for my estimates.

This gets discussed on Statalist from time to time - have a look in the archives.  Here's an example:

> Problem #2: Because -ivreg- is an out-of-date command as of Stata 10, I now
> tried running my regressions with -ivregress-. What is
> different:
> * First of all, now the "singleton dummies - use partial out" error message
> does no longer occur.
> * Second, my first stage and therefore my second stage no longer have
> significant effects in a limited sample (in my bigger sample it still works).
> Question #2:  Why does the error message not occur anymore?

If you re-run the regression using ivreg2 instead of ivregress, you will probably still get the message.


> And under
> the condition that it even makes sense to partial out (i.e. question
> #1) could I somehow do it with ivregress?
> Answers to my questions will be greatly appreciated. Thanks a lot!
> Best,
> Max
> *
> *   For searches and help try:
> *
> *
> *

Sunday Times Scottish University of the Year 2011-2013
Top in the UK for student experience
Fourth university in the UK and top in Scotland (National Student Survey 2012)

We invite research leaders and ambitious early career researchers to 
join us in leading and driving research in key inter-disciplinary themes. 
Please see for further information and how
to apply.

Heriot-Watt University is a Scottish charity
registered under charity number SC000278.

*   For searches and help try:

© Copyright 1996–2016 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index