Which Effect Does the Regression Estimate?

A hundred farmers, an irrigation pump, and the coefficient you get when you control for wealth.

Who has a pump?

Rich farmers

Poor farmers

The truth and the estimates

What this page assumes
  • There are 100 farmers, and you choose how many are rich (default 50).
  • Harvest without a pump: Y0 = 10 + 5·rich + u, with u ~ Normal(0, 1) drawn from a seeded generator. Units are $1,000s.
  • Harvest with a pump: Y1 = Y0 + the effect for the farmer's group (defaults +6 rich, +0 poor). Every farmer in a group has the same effect.
  • Pumps go to exactly round(rate × group size) farmers in each group, so pump ownership depends on wealth and nothing else. Wealth is the only confounder.
  • The true ATE, ATT and ATC use both potential outcomes. Every estimate uses only the observed harvest.
  • The regression is OLS of observed harvest on pump and rich, with conventional standard errors. The blue bar shows ±1.96 SE.
  • Regression weight for a group = n × p × (1 − p), where p is that group's pump rate, normalized to sum to 1.
  • The noise is generated in the browser, so estimates differ slightly from the R workbook (set.seed(104)). The true ATE, ATT and ATC match it exactly.

Left out on purpose: standard errors for the interaction-model ATE, ATT and ATC, and confidence versus prediction intervals. Both are covered in the workbook.