Announcement

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

  • R2-within using xtreg v. reghdfe

    Hi, I am puzzled by the R2's reported when using reghdfe.
    I have a large dataset (100K obs), with 52 year-quarter fixed effects and 1450 firm-city fixed effects. I am clustering by firm-city. Using reghdfe, I get an R2=0.999 and a R2-within =0.005. Using xtreg, the R2-within is 0.37. What explains this big difference and which R2 is the most appropriate to report? Clearly, 0.999 is not credible... Thanks for your help!

  • #2
    R2=0.999 means that almost everything is absorbed by the fixed effects.
    Also, if you have singleton groups and reghdfe is dropping them, then you would get a lower R2 (because the singleton groups are perfectly explained obs.).

    If you run reghdfe with the -keepsingletons- option you should get the same within-R2 as when you run xtreg,fe

    Comment

    Working...
    X