Dear Statalist,

I am struggling with an endogenous treatment in a diff-in-diff model I am using (at the town level). Denoting Y the outcome, POST a dummy equal to 1 for the periods after treatment and TREAT a dummy equal to 1 if the town belongs to the treatment group, the diff-in-diff is therefore expressed as such:
Y = B0 + B1*POST + B2*TREAT + B3*POST_TREAT + u (and I am interested in B3, associated to the interaction between POST and TREAT, which gives the diff-in-diff estimator).

However TREAT is endogenous and I have an instrument for it (which is a "good" instrument that satisfies the conditions). I don't know actually how to implement this on Stata, with -ivreg2-, since the endogenous variable (TREAT) is interacted with POST. Let Z denote the instrument. Is the following code accurate?

ivreg2 Y POST (TREAT POST_TREAT = Z POST_Z)

Or should I only instrument POST_TREAT? As such:

ivreg2 Y POST TREAT (POST_TREAT = POST_Z)

Or only TREAT?

ivreg2 Y POST POST_TREAT (TREAT = Z)

I am a bit perplex since I have never used ivreg2 with two instruments, and do not even know if it is possible.

Thanks in advance for all your remarks!

Olivier