Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Modeling fixed effect using regular reg command

    Hi everyone,

    I came across some materials and they suggested that technically FE effect can be accounted for using dummies e.g.

    xtreg y x1 x2, fe
    is equivalent to
    reg y x1 x2 i.country

    when the panel used xtset country time.

    Suppose x2 is a time invariant variable, if I include x2 into the FE model it will be omitted due to collinearity, however the coefficient can be estimated using the reg equation. So what is the implication for that coefficient? Is it an incorrect estimation?

    Thanks in advance!



  • #2
    Karen:
    I do not think that the two models are equivalent since, in your second code, you implicitly assume that observations referring to the same panel are independent (something that is far from real in panel data analysis).
    In order to check whether -regress- outperforms -xtreg, fe- you should see whether the F-test appearing as a footnote below the -xtreg,fe- outcome table does not reach statistical significance: if that were the case, you should go -regress-, but with standard errors clustered on -panelid- (because your observations are actually not independent, as said above).
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Originally posted by Karen Chan View Post
      Suppose x2 is a time invariant variable, if I include x2 into the FE model it will be omitted due to collinearity, however the coefficient can be estimated using the reg equation.
      Look again, it cannot be estimated while including all (but one) country indicators. Probably the software omits more country indicators than you would expect if you wanted a model equivalent to the FE transformation. By the way, the FE model is technically estimated using regress; it is just that the variables are transformed to express deviations from the panel-specific means.

      Best
      Daniel

      Comment


      • #4
        Dear Carlos and Daniel,

        Apologies for the late reply. Thank you very much for the clarification and explanation for the logic behind the command!

        Best regards
        Karen

        Comment

        Working...
        X