Search

Search papers and lessons

Internal Validity

Level 3 · 10 min read

Internal validity is whether a study's comparison correctly reveals the causal effect inside that study, as opposed to differences between the groups that were compared.

On this page

  • Colour = topic mix
  • Probability
  • Methods
  • Epidemiology
  • Sign in to see your progress

TL;DR

Internal validity asks whether the comparison in a study really measures the effect of the treatment on the people studied. A study has it when the treated and untreated groups would have looked the same, apart from the treatment, had nothing been done. When they differ before treatment, or change in different ways for other reasons, the gap between them mixes the treatment with those differences. Good design is mostly the work of making the comparison fair.

Where you'll see it: in any evaluation of a policy, campaign, reform or institution, where the question is "did this cause that", and the answer depends on how the groups were formed and what happened to them.

Intuition

A fair race

Imagine testing whether a new coaching programme makes runners faster. You let runners sign up, and the keen ones join. Afterwards, the programme group is faster than the non-programme group. Is the coaching responsible? Maybe. But the keen runners were already faster, or would have improved more anyway. The comparison is not fair, because the two groups started in different places.

A study has internal validity when the comparison is fair: the only systematic difference between the groups is the treatment. Think of it as a race where the starting line is the same for everyone. Internal validity is about the start and the rules of the race within the study. It is separate from whether the result would hold for other people or other places, which is external validity.

flowchart LR
  P["people in the study"] --> A["assignment: who gets treated"]
  A --> T["treated group"]
  A --> C["comparison group"]
  T --> D["observed difference in outcomes"]
  C --> D
  B["baseline differences between the groups"] --> D

The observed difference is the treatment effect plus whatever baseline differences and other changes the assignment process brought in. Internal validity is the condition that the last term is small or zero.

Why it is a separate question

A result can be internally valid and still not generalise. A well-run experiment on one city's council may show a clean effect that does not carry to another country. The reverse is also possible: a large, representative survey can produce a result that is externally broad but internally invalid, because the comparison inside it was confounded. Keeping the two questions apart stops a reader from taking a representative sample as proof of causation.

The math

Use the potential outcomes notation from Causal Inference. For each unit ii, Yi(1)Y_i(1) is the outcome if treated and Yi(0)Y_i(0) is the outcome if not. The treatment indicator DiD_i is 1 if unit ii is treated and 0 otherwise. Only one of the two potential outcomes is ever observed for a given unit, so the causal effect of interest is a comparison of two groups.

The average treatment effect on the treated, ATT\mathrm{ATT}, is

ATT=E[Y(1)−Y(0)∣D=1].\mathrm{ATT} = \mathbb{E}[Y(1) - Y(0) \mid D = 1].

It is the average effect among the people who actually received treatment. The quantity a study can compute from observed data is the difference in group means:

E[Y∣D=1]−E[Y∣D=0].\mathbb{E}[Y \mid D = 1] - \mathbb{E}[Y \mid D = 0].

Write the observed outcome as Y=D Y(1)+(1−D) Y(0)Y = D\, Y(1) + (1 - D)\, Y(0). For the treated group the observed mean is E[Y(1)∣D=1]\mathbb{E}[Y(1) \mid D = 1], and for the untreated group it is E[Y(0)∣D=0]\mathbb{E}[Y(0) \mid D = 0]. Add and subtract E[Y(0)∣D=1]\mathbb{E}[Y(0) \mid D = 1], the outcome the treated would have had without treatment:

E[Y∣D=1]−E[Y∣D=0]=E[Y(1)−Y(0)∣D=1]⏟ATT+E[Y(0)∣D=1]−E[Y(0)∣D=0]⏟selection bias.\mathbb{E}[Y \mid D = 1] - \mathbb{E}[Y \mid D = 0] = \underbrace{\mathbb{E}[Y(1) - Y(0) \mid D = 1]}_{\mathrm{ATT}} + \underbrace{\mathbb{E}[Y(0) \mid D = 1] - \mathbb{E}[Y(0) \mid D = 0]}_{\text{selection bias}}.

The first term is the effect we want. The second term is the gap in untreated outcomes between the two groups before treatment. That gap is Selection Bias. A study is internally valid for the ATT when the selection term is zero, and a design earns that by making the untreated outcomes of the two groups match in expectation.

Randomisation does this. If assignment is independent of potential outcomes, then E[Y(0)∣D=1]=E[Y(0)∣D=0]\mathbb{E}[Y(0) \mid D = 1] = \mathbb{E}[Y(0) \mid D = 0], the second term vanishes, and the simple difference in means estimates the average treatment effect. Observational studies have to argue for this condition rather than create it.

Worked examples

Example
Four units, a fixed set of potential outcomes

Four units A, B, C and D have these outcomes:

unitY(0)Y(0)Y(1)Y(1)effect
A253
B462
C132
D374

The average effect over all four is E[Y(1)−Y(0)]=(3+2+2+4)/4=2.75\mathbb{E}[Y(1) - Y(0)] = (3 + 2 + 2 + 4)/4 = 2.75.

Case 1, non-random assignment: A and B are treated, C and D are not.

  1. Treated observed outcomes are Y(1)Y(1) for A and B: 55 and 66, mean 5.55.5.
  2. Untreated observed outcomes are Y(0)Y(0) for C and D: 11 and 33, mean 22.
  3. Naive difference: 5.5−2=3.55.5 - 2 = 3.5.
  4. True effect on the treated: (3+2)/2=2.5(3 + 2)/2 = 2.5.
  5. Selection term: mean Y(0)Y(0) of A and B is (2+4)/2=3(2 + 4)/2 = 3, minus mean Y(0)Y(0) of C and D, which is 22. The term is 11.
  6. Check: 2.5+1=3.52.5 + 1 = 3.5, the naive difference. The study overstates the effect by a full point, because the treated group was already better off.

Case 2, random assignment: each unit is treated with probability one half. Across all ways of assigning treatment, the average treated outcome is the average of Y(1)Y(1) over all four units, (5+6+3+7)/4=5.25(5 + 6 + 3 + 7)/4 = 5.25, and the average untreated outcome is the average of Y(0)Y(0), (2+4+1+3)/4=2.5(2 + 4 + 1 + 3)/4 = 2.5. The expected naive difference is 5.25−2.5=2.755.25 - 2.5 = 2.75, exactly the true average effect. Any single draw can miss, but the design is not biased.

Interpretation: the same four people and the same effects give a biased answer under one assignment rule and an unbiased one under another. What changed is only the assignment process, which is the source of internal validity.

Example
A participatory budgeting program (illustrative numbers)

These numbers are invented for illustration. Suppose some cities adopted a participatory budgeting program and others did not, and the outcome is turnout in local elections, in percent.

beforeafterchange
adopting cities4855+7
non-adopting cities4144+3
  1. A simple comparison after adoption gives 55−44=1155 - 44 = 11 points.
  2. Adopting cities already had higher turnout before the program: 48−41=748 - 41 = 7 points.
  3. Difference in differences: (55−48)−(44−41)=7−3=4(55 - 48) - (44 - 41) = 7 - 3 = 4 points.
  4. Check: 11=4+711 = 4 + 7. Most of the simple comparison is the baseline gap that existed before anyone adopted anything.

The difference-in-differences estimate is internally valid only under the parallel trends assumption: without the program, adopting cities would have risen by the same 3 points as the others. That is a claim about the world, not something the table can prove. If adopters were already on a steeper upward path, the 4 points is still too high.

Interpretation: the program may have raised turnout by about 4 points, but the simple after-only comparison of 11 points would have credited it with most of a difference that predated it.

Tradeoffs and failure modes

Internal validity is threatened in predictable ways. Most of them are versions of the selection term above.

  • Selection. People or places choose, or are chosen, for treatment in ways related to the outcome. This is the main threat in observational work.
  • Confounding. A third factor drives both treatment and outcome, as in Confounding Bias.
  • Reverse causation. The outcome changes the treatment, so the arrow runs the other way too.
  • Measurement error. The treatment or outcome is recorded with error in a way that differs between groups.
  • Attrition. People drop out of the study in ways related to treatment, so the groups that remain differ from the groups assigned.
  • Spillovers. Treated units affect untreated ones, so the comparison group is not clean.
DesignWhat it protects againstWhat it does not fix
Randomised experimentSelection and confounding, in expectationAttrition, spillovers, and results that only hold in the study population
Difference in differencesFixed differences between groupsTrends that differ between groups before treatment
Regression discontinuitySelection around a cutoffEffects far from the cutoff
Instrumental variablesUnmeasured confounding of the treatmentWeak instruments and a strong exclusion assumption
Matching or regression on observablesConfounding by measured factorsAnything unmeasured, which is the usual worry

A common mistake is to treat a well-controlled regression as if it had the same validity as an experiment. Controls only remove the bias from variables you measured, and an omitted variable can still produce Omitted Variable Bias. A study should say which threat it is most worried about and which design answers that threat. A clear statement of remaining threats is part of internal validity, not a weakness to hide.

History

The distinction between internal and external validity was popularised by Donald Campbell and Julian Stanley in their 1963 book on experimental and quasi-experimental designs. They listed threats such as history, maturation, testing and selection, and argued that a study should be judged by how well it rules these out before anyone asks whether its result generalises. Thomas Cook and Campbell extended the framework in 1979 in a book on quasi-experimentation, which is still the standard reference for social-science designs.

The underlying idea that randomisation makes comparisons fair goes back to Ronald Fisher's work on agricultural experiments in the 1920s and 1930s. Donald Rubin's potential outcomes framework, from the 1970s, gave the formal language used above, and Paul Holland's 1986 paper made the link between that framework and causal inference explicit. The concept caught on because it gives researchers a checklist for asking whether their comparison answers the question they care about.

Check yourself

QuestionRecall: in the decomposition of an observed difference in means, what does the selection term measure?Show answer
It measures the difference between the treated and untreated groups in their untreated outcomes, E[Y(0)∣D=1]−E[Y(0)∣D=0]\mathbb{E}[Y(0) \mid D = 1] - \mathbb{E}[Y(0) \mid D = 0]. It is the gap that exists before treatment. When this term is zero, the observed difference equals the effect on the treated.
QuestionComputation: if the true effect on the treated is 2.5 and the untreated baseline gap is 1, what does a naive comparison of means report?Show answer
It reports 2.5+1=3.52.5 + 1 = 3.5. The naive comparison overstates the effect by 1, which is exactly the selection term.
QuestionWhy: a study finds that a training program raises earnings, and the sample was drawn from a nationally representative survey. Does that make the study internally valid?Show answer
Not necessarily. Representativeness speaks to external validity, whether the result generalises to the population. Internal validity depends on the comparison inside the study. If people chose the program, the treated and untreated groups may differ in ways unrelated to the program, and the estimate is still biased despite the representative sample.
QuestionApplied: a city introduces a new voter registration system in some districts, and researchers compare turnout in those districts with turnout in the others after the change. Districts that adopted were already growing faster. What threat does this raise, and what could the researchers do?Show answer
The main threat is selection: adoption was related to a trend that also drives turnout, so the after-only comparison picks up the trend. The researchers could compare changes over time in adopting and non-adopting districts, which is difference in differences, but they must check that the pre-period trends were parallel. They could also look for a design that assigns the system for reasons unrelated to growth, or report the result with the parallel trends assumption stated.

Sources