Announcement

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

  • R Squared using did2s

    Dear Statalist Community,

    I am using did2s for a difference-in-differences analysis. However, this command goes not report the R-squared. My model:

    Code:
     did2s output if subsample==1 [aw=_weights],
     first_stage(i.country_id i.year control1 control2 control3 control4 control5)
     second_stage(treat) treatment(treat) cluster(country_id)
    I was thinking of doing something like:

    Code:
     *predict outputp if e(sample)
     *corr output outputp if e(sample)
     *di r(rho)^2
    However, I was wondering if this would work in the context of did2s...

    Could someone kindly let me know how I can calculate it?

    Thank you!

    Cat Santos
Working...
X