[PDF] [PDF] Difference-in-differences - MSU College of Agriculture and Natural

1 mar 2018 · Regression Discontinuity • Today we'll focus on difference-in-differences – Reminder on basic concepts/theory – Applications in Stata



Previous PDF Next PDF





[PDF] Differences-in-Differences (using Stata)

(using Stata) (work in progress) Difference in differences (DID) Estimation step-by-step The coefficient for 'did' is the differences-in-differences estimator



[PDF] Module 25: Difference-in-Differences Designs - edX Edge

4 1 Implementing PSM in STATA Learning Guide: Difference-in-Differences Differences (DID) regression, which is used to estimate causal effect – under 



[PDF] Diff: simplifying the causal inference analysis with difference - Stata

27 mai 2011 · What is diff? 3 Difference in differences a) Single diff-in-diff b) Diff-in-diff with covariates



[PDF] A Simple Regression Model for the Policy Effect Identi cation - Stata

Difference-In-Differences (DID) estimators are widely used in economics to evaluate the impact of a policy The crucial assumption is referred to as the Parallel- 



[PDF] Difference-in-differences - MSU College of Agriculture and Natural

1 mar 2018 · Regression Discontinuity • Today we'll focus on difference-in-differences – Reminder on basic concepts/theory – Applications in Stata



[PDF] Section 3 Difference-in-Difference Estimator

Problem of unobserved differences between treated and untreated that are correlated with Impractical when n is very large, although STATA automates



[PDF] Simplifying the estimation of difference in differences treatment

22 jan 2013 · Propensity Score (Heckman et al , 1997, 1998) and the quintile regression ( Meyer et al , 1995) In this paper, the Stata's command diff is 



[PDF] Flexpaneldid: A Stata toolbox for causal analysis with - econstor

3 mar 2020 · in-differences approach is particularly useful for causal analysis of The Stata commands flexpaneldid_preprocessing and flexpaneldid



[PDF] A Stata command for causal analysis with varying - econstor

5 fév 2019 · into the difference-in-differences estimation This flexible conditional DID approach ensures that varying treatment phases can be accounted for 

[PDF] haptoglobine basse causes

[PDF] hyperplaquettose causes

[PDF] agglutinines froides traitement

[PDF] maladie de vaquez complications

[PDF] macrocytose causes

[PDF] myélémie causes

[PDF] monocytose causes

[PDF] myelocytes taux normal

[PDF] cours de lobbying pdf

[PDF] exemple lobbying entreprise

[PDF] stratégie de lobbying exemple

[PDF] les lobby les plus puissants

[PDF] exemple de lobbying

[PDF] liste des lobby en france

[PDF] les différents types de lobbying

3/1/181Photo Credit Goes Here

IAPRI-MSU Technical Training

Difference-in-differences

1March2018IndabaAgriculturalPolicyResearchInstituteLusaka,ZambiaRecall from July/September trainings on introduction to impact evaluation (1)

3/1/182

Recall from July/September trainings on introduction to impact evaluation (2)

• Wedidabriefoverviewofcommonmethodsofimpactevaluation(IE)• Randomizedevaluation• PropensityScoreMatching• Difference-in-Differences• InstrumentalVariables• RegressionDiscontinuity

• Todaywe'llfocusondifference-in-differences- Reminderonbasicconcepts/theory- ApplicationsinStata

Learning objectives

• Bytheendoftoday'ssession,youshouldbeableto:

1. UnderstandthekeyassumptionofDIDmodels2. WritedowntheregressionequationforaDID

model

3. Identifywhichparameterintheregression

4. EstimateaDIDmodelinStataandinterpretthe

results

3/1/183

References

• Khandker,S.R.,Koolwal,G.B.andSamad,H.A.,2010.

Othersuggestedreadingsandreferences-DIDsectionsin:• Angrist,J.D.,&Pischke,J.S.(2009).Mostlyharmless

• Angrist,J.D.,&Pischke,J.S.(2015).Mastering'metrics:The • Imbens,G.W.,&Wooldridge,J.(2007).What'snewin • Ravallion,M.(2008).Evaluatinganti-povertyprograms.

REVIEW: With vs. Without • ThekeycomparisonwewanttomakeinIEisbetweenoutcomesWITHVS.WITHOUTtheintervention(project/program/policy)

• Impact="With"outcome-"without"outcome

3/1/184

Impact=With-Without

Source:Khandkeretal.(2010)

Participants'incomeWITHtheprogram?• Y

4 Participants'incomeWITHOUTtheprogram(counterfactualincome)?• Y 2

Programimpact?• Y

4 -Y 2

Introducing Difference-in-Differences (DID)

• WhohasusedDIDbeforeandwhatwereyoustudying? • WhatistheDIDapproachtoconstructingacomparisongroup/ - "TheDIDestimatorreliesonacomparisonofparticipantsand - DIDImpact=(avg.ΔYparticipants)-(avg.ΔYnon-participants) • (avg.Y T after-avg.Y T before)-(avg.Y c after-avg.Y c before)• àwhyit'scalleddifference-in-differencesordoubledifference

3/1/185

DID - visual representation

DIDimpact=(avg.Y

T after-avg.Y T before)-(avg.Y c after-avg.Y c before)

Source:Khandkeretal.(2010)

Changeinparticipants'income?• Y

4 -Y 0

Changeinnon-participants'(control)income?• Y

3 -Y 1

DIDimpact?• (Y

4 -Y 0 )-(Y 3 -Y 1

DID key assumption: parallel (common) trends

Paralleltrends="unobservedcharacteristicsaffectingprogramparticipationdonotvaryovertimewithtreatmentstatus"(Khandkeretal.2010,p.73)• I.e.,trendsintheoutcomevariablewouldbethesameinthetwogroupswithouttreatment(Angrist&Pischke2009);or• "...treatmentandcontroloutcomesmoveinparallelintheabsenceoftreatments"(Angrist&Pischke(2015,p.178)• Implies(Y

1 -Y 0 )=(Y 3 -Y 2

Source:Khandkeretal.(2010)

Changeinparticipants'income(after-before)?• Y 4 -Y 0 Changeinnon-participants'(control)income(after-before)?• Y 3 -Y 1

DIDimpact?• (Y

4 -Y 0 )-(Y 3 -Y 1 )• =Y 4 -Y 0 -Y 3 +Y 1 =Y 4 -Y 3 +Y 1 -Y 0

Substitutein(Y

1 -Y 0 )=(Y 3 -Y 2 )(paralleltrendassumption):• =Y 4 -Y 3 +Y 3 -Y 2 =Y 4 -Y 2

Sameaswithvs.without!

3/1/186

What happens if trends are not parallel?

• DIDestimateisbiased • àSeenext2slidesandhandoutbasedonfiguresin

Ravallion(2008)forillustration

KeyassumptionforDID:Paralleltrends

Source: Ravallion (2008)

Selection bias Same

DID estimate = Treatment effect

Treatment effect

Parallel

3/1/187

Selection bias

Source: Ravallion (2008)

Different

Non-paralleltrendscauseDIDtobebiased

Treatment effect

DID estimate

Treatment effect

(here DID estimate < Treatment effect )

NOTparallel

Can partially test for parallel trends if have multiple pre-treatment waves of data

• Use3wavesofdata:- 2wavespriortoimplementationofNAAIAP(2004&2007TAPRAsurveys)- 1waveafter(during)implementation(2010TAPRAsurvey)• Regresschangeinoutcomevariable(2007minus2004)ondummyforifHH

• Whilenoguaranteethattrendswouldhavebeenparallel2007to2010in

3/1/188

DID simple numerical example

Source:Khandkeretal.(2010)

DIDimpact=(avg.Y

T after-avg.Y T before)-(avg.Y c after-avg.Y c before)

DID data requirements

• Repeatedcross-sections - Separaterandomsamplesfromtherelevant OR• Paneldata- Randomsamplefromtherelevantpopulationand

3/1/189

Regression DID - Basic Setup

Y it =α+γTreated i +λAfter t +δ(Treated i

×After

t it

Where:• iindexesthecross-sectionalunitandtindexestime• Treated=1ifunitisultimatelytreated(exposedtoproject/program/policychange),

• After=1iftimeperiodisaftertheproject/program/policychange,

• Treated×Afteristheinteractionofthesetwovariables• *Note:Notationaboveisforwhen"treatment"ortheproject/program/policychange

• Whichparameterrepresentsthecausaleffectofinterest(assumingthekey Regression DID - Basic Setup - with higher level project/program/policy change Y idt =α+γTreated d +λAfter t +δ(Treated d

×After

t idt • Whichparameterrepresentsthecausaleffectofinterest(assumingthe keyassumptionshold)?

• ThisisthemorecommoninstanceinwhichDIDisused• Wouldwanttoclusteryourstandarderrorsatthedistrictlevel

δ(theparameterontheTreatedXAfterterm)

3/1/1810

Regression DID - Basic Setup - with covariates

Canalsocontrolforadditionalcovariates:

Y idt =α+γTreated d +λAfter t +δ(Treated d

×After

t )+X idt idt • Boldrepresentsvectors• Whichparameterrepresentsthecausaleffectofinterest(assumingthe keyassumptionshold)?

δ(theparameterontheTreatedXAfterterm)

EX)2periods:

Y it =α+λAfter t +δTreated it +c i +u it • Firstdifferencetoremovec i (orestimateviaFE)ΔY i =λ+δΔTreated i +Δu i • Whichparameteristhecausaleffectofinterest (assumingthekeyassumptionshold)?

Panel FE setup without control variables

3/1/1811

EX)2ormoreperiods

Y it =α+Year t

λ+δTreated

it +X it

β+c

i +u it • WhereYearisavectorofyeardummies• EstimateviaFE • Whichparameteristhecausaleffectofinterest (assumingthekeyassumptionshold)?

Panel FE setup with control variables

Examples & tweaking the variable names/notation to fit your particular situation (1)

General:Y

it =α+γTreated i +λAfter t +δ(Treated i

×After

t valuesinacityinMassachusetts

• Newgarbageincineratorconstructionbeganin1981• Havehousingvaluedatafrom1978and1981plusinfoondistancefromhouse

• Let"nearinc"=1ifhouseisnear(within3miles/4.83km)incinerator,=0o.w. (farfromincinerator)

• Let"y81"=1ifyearis1981,and=0o.w.(yearis1978)• HowwouldyouwritetheDIDregressionequationinthiscase?Whatisthekey

parameterofinterest?

3/1/1812

Examples & tweaking the variable names/notation to fit your particular situation (1)

General:Y

it =α+γTreated i +λAfter t +δ(Treated i

×After

t valuesinacityinMassachusetts

Specific:rprice

it =α+γnearinc i +λy81 t +δ(nearinc i

×y81

t it

• Where- "rprice"isthehomevalueinrealUS$- "nearinc"=1ifhouseisnear(within3miles/4.83km)incinerator,=0o.w.

(farfromincinerator) - "y81"=1ifyearis1981,and=0o.w.(yearis1978) Examples & tweaking the variable names/notation to fit your particular situation (2)

General:Y

it =α+γTreated i +λAfter t +δ(Treated i

×After

t it

Example:Angrist&Pischke(2009)-understandingcholeratransmissioninmid-1800s• Havedistrict-leveldatafromLondonondeathratesandwatercompanyin1849&

1852.Let:

- "deathr"bethedeathrateindistrictd- "Lambeth"=1ifdistrictdgetsitswaterfromtheLambethCompany(which

- "y1852"=1ifyearis1852,and=0o.w.(yearis1849)• WritedowntheDIDequationforthisscenarioandusingthesevariablesSpecific:deathr

dt =α+γLambeth d +λy1852 t +δ(Lambeth d

×y1852

t dt

3/1/1813

Examples & tweaking the variable names/notation to fit your particular situation (3)

General:Y

idt =α+γTreated d +λAfter t +δ(Treated d

×After

t idt

Example:Angrist&Pischke(2009)-effectofémin.wageonfastfoodemployment• Havedatafromneighboringstates(NJ&PA).Bothstateshave$4.25minimumwagein

- "employ"betheemploymentlevelofeachrestaurant- "NJ"=1ifstateisNJ,=0ifstateisPA- "Nov92"=1iftimeisNovember1992,and=0o.w.(timeisFebruary1992)• WritedowntheDIDequationforthisscenarioandusingthesevariables.Thinkcarefully

aboutwhichsubscriptstoputoneachvariable.

Specific:employ

ist =α+γNJ s +λNov92 t +δ(NJ s

×Nov92

t ist

DID good to consider if have natural experiment

• Bigpicturequestion:whydomanyHHsselllow,buyhigh(w.r.t.cropprices)?• Hypothesis:"short-termexpenditureneedsforcepoorhouseholdstosell

• Naturalexperiment:Malawichangedprimaryschoolcalendar- 2009:startinDecember.2010:startinSeptember.à HHshavetomakeschool-relatedexpendituresmuchearlierin2010than

3/1/1814

DID & natural experiment example (cont'd)

DIDregression:General:Y

it =α+γTreated i +λAfter t +δ(Treated i

×After

t it

Specific:Cropsales

it =α+γChildren i +λy2010 t +δ(Children i

×y2010

t it

Where• Cropsales=cumulativevalueofHHcropsalesthroughAugustofyeart• Children=#ofchildreninprimaryschool(0,1,2,3,etc.).Orcoulddo0/1• y2010=1ifyearis2010;=0ifyearis2009• EstimateseparatelyforHHsabovevs.belowthepovertyline

What other situations/examples appropriate for DID can you think of? • AndhowwouldyousetupyourDIDregressionequation? • General:Y=α+γTreated+λAfter+δ(Treated×After)+ε

3/1/1815

DID vs. other methods

• KeydifferencebetweenPSMandDID:PSMassumesselectiononobservablesonly,DIDallowsselectiontobeafunctionoftime-constantunobservedfactors(a.k.a.timeinvariantunobservedheterogeneity)

- Wherehaveyouheardthistermbefore?- Whatifselectionisafunctionoftime-varyingunobservables? • Anotherkeydifference: - Randomizedevaluations&PSM-cross-sectionaldata - NeedrepeatedcrosssectionsorpaneldataforDID

ParaphrasedfromKhandkeretal.(2010)

Theory wrap-up

(Source: Angrist & Pischke 2015, pp. 203-204) "MasterStevefu:Wrapitupforme,Grasshopper.

3/1/1816

In Stata - DID (panel or pooled cross-sections)

General:Y

it =α+γTreated i +λAfter t +δ(Treated i

×After

t it istime-constant) interest(assumingthekeyassumptionshold)? • Theoneonthei.Treated#i.AftervariableIn Stata - FE (panel data)

General:Y

it =α+λAfter t +δTreated it +c i +u it varying) interest(assumingthekeyassumptionshold)? • Theoneonthei.Treatedvariable

3/1/1817

Stata exercises

1. Wooldridge(2002)newgarbageincinerator&housingvalues

a. UseKIELMC.DTAin"data"foldertoestimate: rprice it =α+γnearinc i +λy81 t +δ(nearinc i

×y81

t it b. Interpretthekeycoefficientofinterest

Stata exercises

a. Usehh_9198.dtain"data/Khandkeretal2010datafiles" foldertoestimate:lexptot it =α+γdfmfd98 iquotesdbs_dbs35.pdfusesText_40