Causal Methods
SECTION 01

Causal inference

Methods for estimating causal effects from observational data using quasi-experimental variation, discontinuities, differential timing, excluded instruments, or covariate balance, without structural assumptions.

THE IDENTIFICATION PROBLEM
01

Observational data conflates treatment selection with treatment effects. Units that receive treatment differ systematically from those that don't, any naive comparison is confounded.

02

The goal is to find variation in treatment that is as-good-as-random: a policy cutoff, a natural experiment, an instrument. Each method isolates one such source of clean variation.

03

Choosing a method means choosing an identifying assumption. That assumption must be plausible, testable where possible, and clearly stated.

A GENERIC CAUSAL DAGZInstrumentTTreatmentYOutcomeUUnobservedXCovariates
T → YThe causal effect of interest
U → T, YUnobserved confounder (dashed), the problem
Z → TInstrument, shifts T but not Y directly
X → T, YObserved covariate, condition on to close path
CORE ASSUMPTIONS
Overlap / positivityEvery unit has nonzero probability of treatment assignment.
SUTVANo interference between units; one version of treatment.
Ignorability / CIANo unobserved confounders, given covariates.
Parallel trendsDiD: trends would have matched absent treatment.
Exclusion restrictionIV: instrument affects outcome only through treatment.
EXAMPLE: TWFE ESTIMATOR
did_estimate.R
library(fixest)

# Two-way fixed effects DiD
feols(
  insured ~ i(year, treated, ref = 2013) | state + year,
  data = acs_panel,
  cluster = ~state
) |> iplot(
  main = "Effect of Medicaid expansion",
  xlab = "Year relative to expansion"
)
Full pipeline with data prep, diagnostics, and output → Chapter 01, DiD