Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 21

Difference in Difference

Models

1
Difference in difference models
Maybe the most popular identification
strategy in applied work today
Attempts to mimic random assignment
with treatment and comparison sample
Application of two-way fixed effects model

2
Problem set up
Cross-sectional and time series data
One group is treated with intervention
Have pre-post data for group receiving
intervention
Can examine time-series changes but,
unsure how much of the change is due to
secular changes

3
Y

True effect = Yt2-Yt1

Estimated effect = Yb-Ya

Yt1

Ya

Yb

Yt2

t1 ti t2
time
4
Intervention occurs at time period t1
True effect of law
Ya Yb
Only have data at t1 and t2
If using time series, estimate Yt1 Yt2
Solution?

5
Difference in difference models
Basic two-way fixed effects model
Cross section and time fixed effects
Use time series of untreated group to
establish what would have occurred in the
absence of the intervention
Key concept: can control for the fact that
the intervention is more likely in some
types of states
6
Three different presentations
Tabular
Graphical
Regression equation

7
Difference in Difference
Before After
Change Change Difference
Group 1 Yt1 Yt2 Yt
(Treat) = Yt2-Yt1
Group 2 Yc1 Yc2 Yc
(Control) =Yc2-Yc1
Difference Y
Yt Yc
8
Y
Treatment effect=
(Yt2-Yt1) (Yc2-Yc1)

Yc1

Yt1

Yc2

Yt2
control

treatment

t1 t2
time
9
Key Assumption
Control group identifies the time path of
outcomes that would have happened in
the absence of the treatment
In this example, Y falls by Yc2-Yc1 even
without the intervention
Note that underlying levels of outcomes
are not important (return to this in the
regression equation)

10
Y

Yc1

Yc2
Yt1

control

Yt2 Treatment
effect=
(Yt2-Yt1)
treatment (Yc2-Yc1)

t1 t2
time
11
In contrast, what is key is that the time
trends in the absence of the intervention
are the same in both groups
If the intervention occurs in an area with a
different trend, will under/over state the
treatment effect
In this example, suppose intervention
occurs in area with faster falling Y

12
Y

Estimated treatment
Yc1

Yt1
Yc2

True treatment effect control

Yt2 True
Treatment
treatment Effect

t1 t2
time
13
Basic Econometric Model
Data varies by
state (i)
time (t)
Outcome is Yit
Only two periods
Intervention will occur in a group of
observations (e.g. states, firms, etc.)

14
Three key variables
Tit =1 if obs i belongs in the state that will
eventually be treated
Ait =1 in the periods when treatment occurs
TitAit -- interaction term, treatment states after
the intervention
Yit = 0 + 1Tit + 2Ait + 3TitAit + it

15
Yit = 0 + 1Tit + 2Ait + 3TitAit + it
Before After
Change Change Difference
Group 1 0 + 1 0+ 1+ 2+ 3 Yt
(Treat) = 2 + 3
Group 2 0 0 + 2 Yc
(Control) = 2
Difference Y = 3

16
When can you use DID

You want to Evaluate a program or treatment


You have treatment and control groups
You observe them before and after

BUT:
Treatment is not random
Other things were happening while intervention (treatment) was
in effect
You cant control for other confounders

Key Assumption:
Trend in control group approximates what would have happened
in treatment group in absence of treatment

17
Example

Does Free Lunch


Program introduced
in Sao Paulo in 2009
improved the
education Outcome?

18
Why use regression instead of
cross tab
a) Free Estimate of Standard Error

b) Reduce bias from time trends

c)Increase precsion

19
Data
Dpost(before or after
Individual Y DTr(City) policy)
Miguel 40 0 0
Julia 80 1 1
Davi 20 0 0
Sophia 100 1 1
Gabriel 30 0 0
Isabela 0 1 0
Arthur 60 0 1
Mauela 40 1 0
Lucas 60 0 1
Giovanna 90 0 1

20
Result

21

You might also like