A topic in the Open Knowledge Graph — a free, open map of 15,495 topics and the order to learn them in.

Mediation Analysis and Causal Pathways

Research Depth 275 in the knowledge graph ☐ I know this ☆ Set as goal
4topics build on this
2,088prerequisites beneath it
See this on the map →
Causal Inference in EpidemiologyCounterfactual Framework and Potential Outcomes+1 more→→Propensity Score Analysis
causal-inference mechanisms pathways indirect-effects

Core Idea

Mediation analysis decomposes the total effect of an exposure on an outcome into direct effects (not through the mediator) and indirect effects (through the mediator). Natural direct and indirect effects can be estimated using counterfactual definitions even when the mediator is affected by confounders influenced by the exposure.

How It's Best Learned

Start with a simple three-variable example and manually compute direct and indirect effects using regression coefficients. Apply to a real dataset with multiple mediators and visualize the causal pathways.

Common Misconceptions

Explainer

From your work with the counterfactual framework, you know that causal effects are defined by comparing potential outcomes: what would happen to person i under treatment A=1 versus A=0? Mediation analysis applies this same logic to a three-variable structure—an exposure A, a mediator M, and an outcome Y—and asks: how much of the total effect of A on Y flows through M (the indirect path A→M→Y), and how much bypasses M (the direct path A→Y not through M)?

The motivating intuition is epidemiological. Suppose you find that high educational attainment (A) reduces mortality (Y). That's a total effect—but it doesn't tell you *why*. Does education improve health by increasing income (M), which then provides better healthcare access? Or is there a direct effect through biological stress pathways, independent of income? If most of the effect is mediated by income, then an economic intervention could substitute for education; if there's a large direct effect, you'd need to target education itself. The natural direct effect (NDE) is defined as the effect of changing A from 0 to 1 while holding M fixed at the level it would take under A=0. The natural indirect effect (NIE) is the effect of changing M from its value under A=0 to its value under A=1, while holding A constant at 1. Total effect = NDE + NIE.

The regression-based product method makes this concrete. In a linear setting, if you fit: M = α₀ + α₁A + ε₁ and Y = β₀ + β₁A + β₂M + ε₂, then the indirect effect is estimated as α₁ × β₂ (the path A→M times the path M→Y) and the direct effect as β₁. This product method and the difference method (compare total effect to direct-only model coefficient) give the same answer in linear models. The complexity arises in non-linear settings (binary outcomes, survival data), where the two methods diverge and the counterfactual definitions of natural direct and indirect effects require careful identification assumptions.

The critical complication—and the point where regression intuitions most frequently break down—is exposure-induced mediator-outcome confounding. Suppose A causes a variable L that is both affected by A and confounds the M→Y relationship. For example: smoking (A) causes inflammation (L), which is also a confounder of the BMI (M) → cardiovascular disease (Y) relationship. In this case, conditioning on M in a regression model opens a collider path through L, introducing bias. Standard regression cannot recover natural direct and indirect effects in this scenario. The solution requires weighting methods (marginal structural models) or the interventional (separable) effects framework, which avoids "cross-world" counterfactuals. Recognizing when this problem applies—anytime the exposure causally affects anything that also confounds the mediator-outcome relationship—is the practical skill that separates valid from invalid mediation analyses in the applied literature.

Practice Questions 5 questions

Prerequisite Chain

Understanding Zero → The Number Zero → Counting to Five → Counting to 10 → Counting to 20 → Counting a Set of Objects Up to 20 → Cardinality: The Last Number Counted → Matching Numerals to Quantities → Subitizing Small Quantities → Combining Small Groups Within 5 → Number Bonds Within 5 → Number Bonds to 10 → Tens and Ones Place Value → Reading and Writing Three-Digit Numbers → Comparing Three-Digit Numbers → Comparing and Ordering Three-Digit Quantities → Comparing and Ordering Whole Numbers → Comparing Numbers 1 to 20 → Ordering Numbers to 20 → Number Line 0 to 20 → Addition Within 20 → Doubles and Near Doubles → Doubles Facts Within 10 → Near Doubles Facts Within 20 → Mental Math Strategies for Addition → Mental Math: Adding and Subtracting Tens → Addition Within 100 → Repeated Addition as Multiplication → Multiplication as Equal Groups → Multiplication: Arrays → Basic Multiplication Facts (0s, 1s, 2s, 5s, 10s) → Multiplication Facts Within 100 → Division as Equal Sharing → Division as Grouping (Measurement Division) → Division: Grouping (Repeated Subtraction) Model → Division: Fair Sharing Model → Division as Equal Sharing → Division as Grouping → Basic Division Facts → Division Facts Within 100 → Multiplication and Division Fact Families → Relationship Between Multiplication and Division → Division Facts as Inverse of Multiplication → Remainders and Quotients in Division → Division Word Problems → Multi-Step Word Problems → Solving Multi-Step Word Problems → Multiplication Word Problems → Division Word Problems → Introduction to Long Division → Factors and Multiples → Prime and Composite Numbers → Equivalent Fractions → Relating Fractions and Decimals → Decimal Place Value → Reading and Writing Decimals → Comparing and Ordering Decimals → Adding and Subtracting Decimals → Multiplying Decimals → Dividing Decimals → Dividing Fractions → Mixed Number Arithmetic → Order of Operations → Integer Order of Operations → Variable Expressions → Combining Like Terms → Variables and Expressions Review → Introduction to Polynomials → Adding and Subtracting Polynomials → Multiplying Polynomials → Multiplying Binomials (FOIL) → Factoring Trinomials → Factoring Completely → Introduction to Rational Expressions → Simplifying Radical Expressions → Segments and Distance → Triangle Inequality Theorem → Similar Triangles: AA Similarity → Similar Triangles: SSS and SAS Similarity → Proportions in Similar Triangles → Similar Right Triangles and the Geometric Mean → Right Triangle Trigonometry Introduction → Sine, Cosine, and Tangent Ratios → Special Right Triangles: 30-60-90 → Trigonometric Ratios Review → Radian Measure → Converting Between Degrees and Radians → The Unit Circle → Graphing Sine and Cosine → Graphing Tangent and Reciprocal Trigonometric Functions → Derivatives of Trigonometric Functions → Antiderivatives → Indefinite Integrals → Basic Integration Rules → Riemann Sums → Definite Integral Definition → Double Integrals: Definition and Setup → Iterated Integrals and Fubini's Theorem → Double Integrals over Rectangular Regions → Double Integrals over General Regions → Applications of Double Integrals: Area, Mass, and Moments → Triple Integrals in Cartesian Coordinates → Triple Integrals in Cylindrical and Spherical Coordinates → Change of Variables and the Jacobian Determinant → Applications of Triple Integrals: Volume and Mass → Vector Fields and Their Representations → Line Integrals of Vector Fields → Work and Circulation → Line Integrals of Scalar and Vector Functions → Fundamental Theorem for Line Integrals → Conservative Vector Fields → Conservative Vector Fields and Potential Functions → Green's Theorem and Its Applications → Divergence Theorem: Flux and Outflow → Divergence Theorem → Electric Flux and Divergence Theorem → Gauss's Law: Integral Form and Meaning → Solving Problems with Gauss's Law → Conductors in Electrostatic Equilibrium → Capacitance and Capacitors → Parallel Plate Capacitor Geometry and Field → Dielectric Constant and Relative Permittivity → Electric Field Inside Dielectric Materials → Dielectric Materials and Polarization → Dielectric Susceptibility and Permittivity → Energy Density in Electric Fields → Electric Current and Current Density → Electrical Resistance and Resistivity → Ohm's Law and Circuit Elements → Electromotive Force (EMF) and Batteries → Kirchhoff's Circuit Laws: Voltage and Current → DC Circuit Network Analysis Methods → Transient Response in RC Circuits → RC Circuits → LC and RLC Circuits → AC Circuits: Fundamentals → Impedance and Reactance → AC Power and Resonance → Electromagnetic Waves → Postulates of Special Relativity → Time Dilation → Length Contraction → Lorentz Transformation → Relativistic Velocity Addition → Relativistic Momentum and Energy → Mass-Energy Equivalence and E=mc² → Photons as Particles with Energy and Momentum → Planck-Einstein Relation: Energy and Frequency → Photoelectric Effect → The Photon: Light as Quanta → Compton Scattering → Wave-Particle Duality → de Broglie Wavelength → The Schrödinger Equation → State Vectors and Wavefunctions → Quantum Superposition → The Measurement Problem → Interpretations of Quantum Mechanics → Postulates of Quantum Mechanics → Observables and Quantum Operators → Commutators and Commutation Relations → Quantum Angular Momentum → Quantum Mechanical Treatment of Hydrogen → Solving the Schrödinger Equation for Hydrogen Atom → Quantum Numbers → Electron Configuration → Periodic Trends → Covalent Bonding → Electronegativity and Bond Polarity → Ionic Bonding → Lewis Structures → Resonance Structures and Delocalized Electrons → Resonance and Formal Charge → Molecular Polarity and Dipole Moments → Intermolecular Forces → States of Matter and Phase Changes: Melting, Boiling, and Sublimation → Gas Laws and the Ideal Gas Equation → Gas Stoichiometry and Volume-Volume Calculations → Thermochemistry and Enthalpy → Heat Capacity and Calorimetry → Entropy and Molecular Disorder → Spontaneity and ΔG → Entropy and Gibbs Free Energy → Chemical Equilibrium → Acid-Base Chemistry → Weak Acid Ionization → Weak Base Ionization → Acid and Base Strength: Ka, Kb, and Ionization → Leaving Groups and Nucleofugality → SN2 Substitution Reactions → SN1 Substitution Reactions → E1 Elimination Reactions → Alcohols and Ethers: Structure, Properties, and Nomenclature → Reactions of Alcohols → Aldehydes and Ketones: Structure and Reactivity → Oxidation Reactions in Organic Chemistry → Oxidation of Alcohols to Aldehydes and Ketones → Aldehyde and Ketone Structure and Nomenclature → Nucleophilic Addition to Aldehydes and Ketones → Carboxylic Acids and Their Derivatives → IUPAC Nomenclature of Carbonyls and Carboxylic Acids → IUPAC Nomenclature of Alkenes → Electrophilic Addition to Alkenes → Aromaticity and Benzene → Electrophilic Aromatic Substitution (EAS) → Nucleophilic Aromatic Substitution (SNAr) → Nucleophilic Acyl Substitution → Amines: Structure, Basicity, and Reactions → Amine Reactivity: Nucleophilicity and Basicity → Amino Acid Structure and Properties → Peptide Bonds and Polypeptide Formation → Protein Primary Structure → Protein Secondary Structure → Protein Tertiary Structure → Enzyme Structure and Function → Transcription: DNA to RNA → RNA Types and Structure → RNA Structure and Intramolecular Base Pairing → RNA Processing and Splicing → Translation: RNA to Protein → Ribosomes: Protein Synthesis Machines → Translation: Initiation and Elongation → Post-Translational Modifications → Proteasomal Degradation and Ubiquitin-Mediated Marking → Cell Cycle Regulation and Checkpoints → Mitosis → Cytokinesis → Meiosis → Chromosomal Theory of Inheritance → Mendelian Genetics → Dominance, Recessiveness, and Allelic Interactions → Sex-Linked Inheritance → Non-Mendelian Inheritance Patterns → Population Genetics and Hardy-Weinberg Equilibrium → Natural Selection → Genetic Drift → Evolutionary Genetics Foundations → Allele Frequency Change and Evolutionary Dynamics → Gene Flow and Population Structure → Gene Flow and Selection: Opposing Forces → Gene Flow → Hardy-Weinberg Equilibrium → Mating Patterns: Inbreeding and Assortative Mating → Speciation → Phylogenetics and Evolutionary Trees → Cladistics and Biological Classification → Comparative Phylogenetic Methods for Evolutionary Analysis → Evolutionary Comparative Anatomy: Homology and Analogy → Animal Body Plans and the Major Animal Phyla → Osmoregulation and Nitrogenous Wastes Across Animals → Renal Physiology and Fluid Balance → Glomerular Filtration and Filtration Rate Regulation → Glomerular Filtration Pressure and Filtration Rate → Glomerular Filtration Rate and Autoregulation → Tubular Reabsorption, Secretion, and Selective Transport → Loop of Henle and Countercurrent Multiplication Mechanism → Collecting Duct Water Reabsorption and ADH Regulation → Acid-Base Balance and Renal Regulation → Acid-Base Balance and Respiratory Compensation → Respiratory Control Mechanisms → Gas Transport and Regulation of Ventilation → Fluid Compartments, Electrolyte Balance, and Acid-Base Regulation → Minerals and Trace Elements in Human Nutrition → Nutrient Requirements and Dietary Reference Intakes → Dietary Guidelines, Reference Intakes, and Food Patterns → Nutrition Across the Lifespan: Pregnancy, Infancy, Childhood, and Aging → Social Determinants of Health → Health Promotion and Behavior Change Models → Risk Communication and Behavior Change → Health Behavior Change and Population Intervention Strategies → Health Promotion Program Design and Behavior Change Theories → Health Communication, Message Design, and Audience Engagement → Health Literacy and Public Health Communication → Biostatistics in Public Health → Multivariable Regression in Epidemiology → Mediation Analysis and Causal Pathways

Longest path: 276 steps · 2088 total prerequisite topics

Prerequisites (3)

Leads To (1)