Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: two-way fixed effects


From   "Martin Wang" <[email protected]>
To   "statalist" <[email protected]>
Subject   st: two-way fixed effects
Date   Wed, 25 Jun 2008 03:29:51 +0800

Dear Statalist,

I have an old question, which command should I use for two-way fixed effects? For example if I want to control both year and firm fixed effects. I find two methods as follows:
1)
. egen dummy = group(firm year)
. xi: reg quantity price i.dummy

and 2)
. xi: reg quantity price i.firm i.year

I find the two methods gave the same estimation of coefficient, but method 2) seems to yield a large t-stat. Could someone please advise which one should I use?

Many thanks!

Martin



*
*   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