Inverse probability weighting
Reconstruct intervention means with inverse assignment probabilities and distinguish exact identities from fitted estimators.
On this page
The question for today
What you’ll understand
- Derive the IPW identification identity by conditioning on baseline covariates.
- Distinguish Horvitz–Thompson and self-normalized estimators.
- Explain the influence of rare assignments and target-specific weights.
Inverse probability weighting compensates for the fact that some baseline types are less likely to appear in a treatment arm. Each observed outcome represents additional units with comparable baseline characteristics under a hypothetical intervention. This interpretation depends on the causal identification conditions, not merely on computing reciprocals. We use the true propensity score first to derive an exact population identity, then discuss finite-sample estimates and the instability caused by rare treatment assignments.
Conditioning cancels the assignment probability
Within a baseline stratum, the expectation of the treated outcome indicator is the propensity times the observed treated conditional mean. Dividing by that same propensity cancels the selection probability. Averaging over the baseline distribution returns the standardized intervention-one mean under consistency and conditional exchangeability. The control identity uses one minus the propensity. Subtracting gives ATE. The formula requires the relevant denominators to be positive wherever the target has support and enough integrability for the expectations to exist.
This is a statement about the observed probability law and its relation to potential outcomes under assumptions. It does not mean that a large weight creates information about a never-observed treatment alternative. At a structural zero score, the treatment numerator is always zero and division cannot recover the missing mean. With a very small score, a rare treated observation can dominate an estimate. The algebra correctly describes the target while leaving a challenging variance and finite-sample problem.
Known design probabilities and fitted propensities behave differently
A Horvitz–Thompson mean divides the weighted outcome total by the original sample size. In a fixed finite population with known randomized assignment probabilities, the corresponding inverse-probability estimator is exactly design-unbiased for the finite intervention mean. That claim concerns random assignment and known probabilities. Substituting estimated observational propensities generally does not preserve exact finite-sample unbiasedness, even if the model is correctly specified. Consistency and uncertainty then depend on the fitting method and regularity assumptions.
A Hájek estimator instead divides each weighted outcome total by its arm’s observed weight total. It often has useful finite-sample stability and keeps a binary-outcome arm mean within the observed outcome range, but it is a ratio estimator and is generally not exactly unbiased. Its ATE subtracts two separately normalized arm means. The two methods can agree asymptotically under appropriate conditions while differing substantially in a small sample. Naming the normalization makes an estimate reproducible and prevents a probability identity from being mistaken for every possible weighting implementation.
Weights encode a target and a variance cost
For an ATE pseudo-population, treated units receive reciprocal propensity weights and controls receive reciprocal complement weights. For an ATT comparison, treated units retain unit weight while controls are tilted by the propensity odds, followed by the appropriate normalization. Applying one formula and labeling the result as the other target is incorrect when effects vary. Stabilizing weights by arm constants leaves separately normalized means unchanged, but does not magically restore support or remove confounding.
A common descriptive diagnostic is the squared sum of weights divided by the sum of squared weights, often called a weight effective sample size. It measures concentration of weights under a specific arm and normalization; it is not a universal replacement for the actual sampling variance or dependence structure. Truncating extreme weights may improve precision at the cost of bias for the original target. Report the chosen rule, overlap, and target interpretation rather than presenting a narrow standard error as proof that the weighted intervention contrast is identified.
Work it through
Recover the standardized means from weighted event masses
For binary Y, use two baseline strata of probability one half, scores 0.2 and 0.8, treated outcome means 0.2 and 0.6, and control means 0.1 and 0.5. Compute the IPW means from joint event masses.
The treated-success masses in the two strata are (1/2)·0.2·0.2=0.02 and (1/2)·0.8·0.6=0.24. Divide by their scores to get contributions 0.10 and 0.30.
The control-success masses are (1/2)·0.8·0.1=0.04 and (1/2)·0.2·0.5=0.05. Divide by control probabilities 0.8 and 0.2 to get contributions 0.05 and 0.25.
The resulting intervention means are 0.40 and 0.30, giving effect 0.10. This equals outcome standardization because both evaluate the same identified functional with the true probabilities.
Weighting corrects the stipulated stratum mixture; its numerical agreement does not independently test the conditional exchangeability assumption.
The living notebook
Explore the model
Interactive lab · probability
Rare assignments can leave an empty cell
Reset, set probability 0.05 and trials 20. Predict one treated unit on average, count variance 0.95, and probability of no treated unit 0.95²⁰, about 0.3585. Inspect the zero bar. A treated outcome in this stratum would carry inverse score twenty. Reset, set p=0.5,n=20 and compare the count mean ten and weight two. The exact binomial instrument models independent assignments, not causal outcomes or fitted weights. Changes retain time; Reset restores both controls and zero time.
- Mean · np
- 5
- Variance · np(1−p)
- 2.5
- Total probability
- 1
These are exact binomial probabilities for independent trials with one fixed success probability. Playback tours the distribution; it does not resample outcomes. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forA nonzero treatment probability can coexist with a substantial finite-sample chance of observing no treated outcome in a stratum.
Pause & reason
Check your understanding
Your turn
Try it yourself
In a four-unit illustration with known treatment probability one half, exactly one unit is treated, and its observed outcome is one. Compute its treated-arm Horvitz–Thompson mean using n=4 and its Hájek mean. Are these equal?
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
The treated outcome has weight two; distinguish the original sample size from the observed treated weight total.
Compare with the solution
The weighted treated outcome total is two. Dividing by the original sample size four gives Horvitz–Thompson mean one half. The observed treated weight total is also two, so the Hájek mean is two divided by two, or one. They differ in this realized sample. If assignments were independent Bernoulli draws with known probability one half, the HT mean would be design-unbiased over all assignments; the ratio has an empty-arm issue on assignments with no treated units and needs a stated convention or a design ensuring nonempty arms.
Keep the idea
Take it with you
- True-propensity weighting and outcome standardization evaluate the same causal functional under identification assumptions.
- Known-design HT unbiasedness does not imply finite-sample unbiasedness with fitted scores or ratio normalization.
- Rare assignments, weight concentration, and target-changing modifications affect interpretation and uncertainty.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.