Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: re: Estimating three way fixed effects


From   "Richard Upward" <[email protected]>
To   <[email protected]>
Subject   st: re: Estimating three way fixed effects
Date   Fri, 09 Jul 2004 09:42:05 +0100

Tim Sass asked about estimating a model with three-way fixed effects for students, schools and time.   He cannot include dummy variables for every school because he has lots of schools.

The solution proposed by Greene (Econometric Analysis, 2nd ed., pp. 468-469) which is a kind of "double demeaning" only works (AFAIK) in a two-way model where one of the effects is time.  (Scott Merryman's post showed that this method does work in this case).  I don't think it would work with the type of model Tim is trying to estimate.  This is why he is not getting the same answer as when he explicitly included the dummies.

The reason this is a difficult problem is explained by Abowd, Kramarz & Margolis in a complicated paper 1999 (Econometrica 67(2) pp251-333) .  These authors have developed specialised methods for estimating these kind of models, but I think they are a long way off being estimable in Stata.  The problem arises because pupils' movement between schools is "unpatterned" which means that double-demeaning doesn't work.  (If there is an easy solution, I'd love to hear about it...)

So, the only sure-fire solution I know of is to create a dummy for each school and then demean  within-i to get rid of pupil effects.  This is explained in the presentation I gave at the Stata User's Group last week, which I think will appear on RePEc. (http://ideas.repec.org/s/boc/usug04.html)

Note that once you have "pupil-demeaned", the school fixed-effects will only be identified for those schools which have pupils which move to other schools.  If you have a sample of schools, this could be a very small number of schools.  This might help, because it reduces the number of dummies you need to include.  This was also explained in the Stata User's Group presentation.  

Second, estimates of the school fixed-effects are identified only by pupils who move school.  Once again, if you have a sample of schools this could be a tiny fraction of the total number of pupils.  This suggests a 2-step solution to the problem.  First, estimate the model using only pupils who move schools to get an estimate of the school fixed-effect.  This requires lots of dummy variables but hopefully only a tiny fraction of pupils, so if you have a reasonable amount of memory you should be OK.  Copy the estimated school fixed effect into a single variable.  Then estimate the second stage model using all pupils in the usual way (demeaning to get rid of pupil fixed effects and including a time dummy).  The school fixed effect is controlled for by the estimated variable from the first stage.  

There are some tricky issues regarding standard errors with this method which we do not yet have a solution to!

Richard



Richard Upward
School of Economics
University of Nottingham
University Park
Nottingham NG7 2RD
Tel: +44 (0) 115 95 14735

http://www.nottingham.ac.uk/economics/staff/details/richard_upward.html


This message has been scanned but we cannot guarantee that it and any
attachments are free from viruses or other damaging content: you are
advised to perform your own checks.  Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index