# Difference in Difference with leads and lags

Following this previous thread, I am somewhat confused about using a difference-in-difference estimator with leads and lags. What does the esimation equation look like exactly? I have found several equations, but it was not clear to me what they exactly mean. For example, here on page 9 Pischke writes down this equation:

$Y_{ist} = \gamma_s + \lambda_t + \sum_{j=-m}^{q} \beta_j D_{st+j} + e_{ist}$

Here $Y_{ist}$ is the outcome variable (for example) for individual $i$ in state $s$ in time $t$. State fixed effects are $\gamma_s$, while $\lambda_t$ are time dummies for each period.

I am familiar with the sum notation, but I do not fully understand how the difference-in-difference estimator $D_{st+j}$ is defined here. When exactly is $D_{st+j}$ $1$ or $0$? How do we interpret these regressors? Could someone please also provide an example? Furthermore, why does the equation above not suffer from a dummy variables trap?

The short answer is that $D_{st+j}$ is the product of the time and treatment dummy indicators. These test the difference-in-differences effects. However, how you create the indicator variables affects the interpretation.
• Thank you. Could you provide an example regression equation for multiple periods where $D_t+j$ is spelled out, e.g. for 2 leads and lags? Do I interact treatment with a time dummy for a single period (e.g. $j$) or multiple dummies indicating all periods after a certain period (e.g. $j$). So suppose $T$ is a dummy for treated states and $I_j$ is a dummy equal 1 if we are in period $j$. and treatment occurs in 2010. Do I estimate $Y_{ist}= \gamma_s + \lambda_t + \beta_1 I_{2008}*T_s + \beta_2 I_{2009}*T_s + \beta_3 I_{2010}*T_s + \beta_4 I_{2011}*T_s$? If so, how would you interpret the betas? – Bob May 3 '18 at 12:54