Medical AtlasPROJECT IMG
✎ Sketch Notes🏛️ 3D LibraryMy Desk

Confounding & effect modification

A confounder is a third variable associated with both exposure and outcome that is not on the causal pathway; it distorts the apparent association. Effect modification is a real difference in effect across subgroups. Randomization, matching, restriction, stratification and regression control confounding.

Overview

Confounding happens when the observed relationship between an exposure and an outcome is partly or wholly explained by a third factor. A confounder must:

  1. Be associated with the exposure,
  2. Be an independent risk factor for the outcome, and
  3. Not lie on the causal pathway between them.

Classic example: coffee drinking appears linked to lung cancer. Smoking is the confounder: coffee drinkers smoke more, and smoking causes lung cancer. When the data are split into smokers and nonsmokers, the coffee association disappears.

Detecting confounding

Compare the crude (unadjusted) measure with the stratified or adjusted measure.

Finding after stratifying by the third variableInterpretation
Stratum-specific RRs are similar to each other but differ from the crude RRConfounding; report the adjusted RR
Stratum-specific RRs differ from each otherEffect modification; report each stratum separately
Stratum RRs similar to each other and to the crude RRNeither

Example: crude RR 3.0; RR 1.1 in smokers and 1.0 in nonsmokers = confounding by smoking. Crude RR 3.0; RR 6.0 in smokers and 1.2 in nonsmokers = effect modification.

Effect modification

Effect modification (interaction) is not a bias. It is a true biological difference in how an exposure works in different subgroups, and it should be described, not removed. Classic examples: oral contraceptives raise venous thrombosis risk much more in women with factor V Leiden; asbestos raises lung cancer risk far more in smokers (a multiplicative interaction). Effect modification is often reported in subgroup analyses of trials.

Controlling confounding

StageMethodNotes
DesignRandomizationOnly method that controls unknown confounders
DesignMatchingCases and controls matched on age, sex; common in case-control studies
DesignRestrictionEnroll only nonsmokers; limits generalizability
DesignCrossoverEach patient is own control
AnalysisStratificationAnalyze within levels of the confounder
AnalysisMultivariable regression, propensity scoresAdjust for many measured confounders at once

Analysis methods can only adjust for confounders that were measured. Residual confounding by unknown factors remains in all observational studies.

Related concepts

  • Confounding by indication: patients who receive a drug are sicker (the indication itself causes the outcome), so the drug looks harmful. Common in observational drug studies.
  • Mediator: a variable on the causal pathway (for example, LDL cholesterol between diet and heart disease). Adjusting for a mediator wrongly removes part of the true effect, so it is not a confounder.
  • Lead-time and length-time biases are specific to screening studies, not confounding.

Worked example

A study finds that people who carry matches have a higher rate of lung cancer (crude RR 4.0). When participants are divided into smokers and nonsmokers, the RR for carrying matches is 1.0 in each group. Smoking is linked to carrying matches and independently causes lung cancer, and carrying matches does not cause smoking, so smoking is a confounder, and the true adjusted RR is 1.0. Compare a trial in which a drug lowers stroke risk by 40% in patients with atrial fibrillation but has no effect in patients without it; that is effect modification by atrial fibrillation, and the authors should report the subgroups separately rather than one pooled result.

🔥 Exam pearls

  • Association disappears after stratifying by a third variable = confounding.
  • Effect differs between subgroups = effect modification, not a bias.
  • Best way to control both known and unknown confounders: randomization.
  • Case-control studies commonly use matching to control confounding.
  • A variable on the causal pathway is a mediator, not a confounder.
  • Sicker patients more likely to get a drug = confounding by indication.
© 2026 Project IMG · Content from Project IMG labs and atlases · For education only, not medical advice.