Announcement

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

  • First Difference with Non-Consecutive Waves and Controls

    Hello everyone,

    for my panel analysis I would like to apply a first-difference approach. So far, I have been using the following specification:
    reg D.schoolgrades D.wave, nocons However, I do not want to compare two consecutive waves, but instead specifically the waves from 2019 and 2022. How do I need to adjust my code in order to compare exactly these two waves? And how can I include control variables in this setup?

    Many thanks!

  • #2
    A FD with exactly 2 time points is equivalent to a FE regression. You have multiple options. Option 1: recode your waves (2019 = 0, 2022 = 1), use this in xtset and then use xtreg, fe. Option 2: convert the dataset to wide format (reshape wide), then compute the difference manually (generate diff = outcome2022 - outcome2019) and estimate a OLS regression (regress). Regarding control variables, as long as they are also time-variant, you can just include them (xtreg approach) or also code their difference (regress approach). For time-constant controls, these drop out automatically in the xtreg, fe model. I am not sure if there is any benefit to include them in the OLS approach. Personally, I would probably use the xtreg approach.
    Best wishes

    Stata 18.0 MP | ORCID | Google Scholar

    Comment

    Working...
    X