Announcement

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

  • First differences variable using did_multiplegt

    Hello everyone,

    I am working with panel data and doing a DID analysis of public policy outcomes in India using elections at the state level as a "treatment." I ran the command did_multiplegt designed by de Chaisemartin and d'Haultfoeuille with the following specification (after reshaping the data and setting up the panel data analysis):

    did_multiplegt logtotpdac ac year treatedac, placebo(1) firstdiff_placebo if_first_diff(fd_treatedac==1) breps(100) cluster(ac)

    I am specifically looking at generating estimates for different treatments when electoral constituencies were not won consecutively (something that xthdidregress cannot handle, since observations treated once are "forever" treated). In order to do that I added the option if_first_diff() which eliminates observations from the analysis that were not initially treated. I had to generate a first differences variable to use with the if_first_diff() option. I did so by simply using the d. operator.

    However, when I tried to run did_mutiplegt with the if_first_diff() specification, I got an error message "fd_treatedac not found" (fd_treatedac is the name of the first differences variable). I tried to work around the syntax, to no avail (I even converted the first diff variable to string, but got the same error message). Is there something about the syntax with first difference variables I should know and I forgot?

    One thing that I thought was particularly puzzling: when I run

    su fd_treatedac if e(sample)

    Stata says that there 0 observations in the variable.

    Thanks for letting me know.
    Thibaud.


Working...
X