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

st: two-way fixed effects

From   "Martin Wang" <>
To   "statalist" <>
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:
. 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!


*   For searches and help try:

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