I have a dataset where each row represents one childbirth delivery. I would like to estimate the effect of a municipality level policy which is believed to have affected a given variable X in different ways. Thus my key independent variable with be the interaction between X and a dummy for post-policy period. I would like to include municipality fixed effects as well as to cluster the standard errors at the municipality level.
If I would be to force a panel structure to my data, the panel variable would be each child born (which only shows up once in the dataset). Stata would not run the command:
Code:
. xtset id d_pos panel variable: id (weakly balanced) time variable: d_pos, 0 to 1 delta: 1 unit . . gen d_pos2 = d_pos . . xtivreg2 peso d_pos2 (d_pc = trat), fe cluster(mun) Warning - singleton groups detected. 6097656 observation(s) not used. no observations r(2000); end of do-file r(2000); .
0 Response to IV with fixed effect for data which has not a traditional panel structure
Post a Comment