Tutorials › Causal Inference › Interventional Direct and Indirect Effects

Interventional Mediation and Mechanisms · Tutorial 803 of 972

Interventional Direct and Indirect Effects

Learn to define and calculate interventional direct and indirect effects as risk differences when treatment and outcome are binary.

Advanced 10 min read

What You'll Learn

  • Define a stochastic mediator intervention using the population mediator distribution under each treatment level.
  • Calculate the mean outcome risk under a treatment level and a stochastic mediator draw.
  • Distinguish an interventional direct effect from an interventional indirect effect.
  • Interpret each effect as a risk difference for a specified reference distribution.
  • Recognize why effects can differ when the treatment or mediator reference level changes.
  • Avoid treating a causal estimand as identified merely because it has been defined.

Why Define Effects Through Mediator Distributions?

A mediation question asks how outcomes might change if treatment changed while the mediator were handled in a specified way. One option is to assign each person the mediator value that the same person would have had under another treatment. Interventional effects use a different construction: they draw a mediator value from a population distribution associated with a treatment level. This makes the intervention explicitly stochastic and gives a clear population-level meaning to the resulting contrasts.

This tutorial focuses on marginal mediator distributions: the draw is from the target population’s mediator distribution under treatment 0 or treatment 1, without conditioning that distribution on baseline covariates. Different choices of mediator intervention define different estimands, so the reference distribution must be named when reporting an effect.

Definition: Let \(A\) be a binary treatment, \(M\) a mediator, and \(Y\) a binary outcome. Let \(M(a)\) denote the mediator value under treatment \(a\), and let \(Y(t,m)\) denote the outcome under treatment \(t\) and mediator value \(m\). For each \(a\in\{0,1\}\), define \(G_a\) as a random draw from the population distribution of \(M(a)\), made independently of the person’s counterfactual outcomes. The quantity \(\psi(t,a)=E[Y(t,G_a)]\) is the mean outcome risk under treatment \(t\) when the mediator is assigned by this stochastic intervention.

Because \(Y\) is binary, its expectation is a risk. Thus \(\psi(t,a)\) is the population risk under a specified treatment and mediator intervention. The first argument \(t\) says which treatment is set for the outcome response; the second argument \(a\) identifies the treatment level whose mediator distribution supplies the random draw. These arguments need not be equal.

Write \(q_a(m)=P(M(a)=m)\) for the exposure-specific mediator distribution and \(r_{tm}=E[Y(t,m)]\) for the mean outcome under treatment \(t\) and mediator value \(m\). For a discrete mediator, the stochastic-intervention risk is

$$ \psi(t,a)=\sum_m r_{tm}q_a(m). $$

In words, multiply the outcome risk for each mediator value by the probability that the intervention draws that value, then add across mediator values. For binary \(M\), if \(q_a=P(M(a)=1)\), this becomes

$$ \psi(t,a)=r_{t0}(1-q_a)+r_{t1}q_a. $$

Interventional Direct and Indirect Effects

An interventional direct effect compares treatment levels while holding the stochastic mediator intervention fixed. An interventional indirect effect compares mediator-distribution interventions while holding the treatment level fixed. On the risk-difference scale, define

$$ \operatorname{IDE}(a^*)=\psi(1,a^*)-\psi(0,a^*),\qquad \operatorname{IIE}(t)=\psi(t,1)-\psi(t,0). $$

Here \(a^*\) is the chosen reference level for the mediator distribution, and \(t\) is the treatment level at which the indirect contrast is evaluated. For example, \(\operatorname{IDE}(0)\) compares treatment 1 with treatment 0 while drawing the mediator from its treatment-0 distribution. Meanwhile, \(\operatorname{IIE}(1)\) compares draws from the treatment-1 and treatment-0 mediator distributions while holding treatment at 1.

Each contrast is a difference in outcome risks, reported in percentage points when risks are converted to percentages. A positive direct effect means that the risk is higher under treatment 1 than treatment 0 with the stated mediator intervention held fixed. A positive indirect effect means that replacing the treatment-0 mediator distribution with the treatment-1 distribution raises risk at the stated treatment level. Neither interpretation is an association claim: these are contrasts between specified causal interventions.

Important distinction: The definition of an interventional effect specifies a causal quantity; it does not by itself establish that the quantity can be identified from observed data. The examples below stipulate the causal outcome risks and mediator distributions needed for calculation. Identification from observational data requires additional conditions and is a separate question.

Calculating the Stochastic-Intervention Risk

The weighted-average formula follows from conditioning on the mediator value drawn by the intervention. Since \(G_a\) takes value \(m\) with probability \(q_a(m)\), the law of total expectation gives

$$ E[Y(t,G_a)] =\sum_m E[Y(t,G_a)\mid G_a=m]P(G_a=m) =\sum_m E[Y(t,m)]q_a(m) =\sum_m r_{tm}q_a(m). $$

The middle equality uses the intervention’s construction: when the draw is \(m\), the outcome is the counterfactual outcome under treatment \(t\) and mediator value \(m\). For binary \(Y\), each \(r_{tm}\) is a probability between 0 and 1. The formula therefore averages valid risks using nonnegative weights that sum to 1.

Worked Example: Direct and Indirect Risk Differences

Suppose a hypothetical population has binary mediator \(M\). The stipulated probabilities of \(M=1\) under treatment 0 and treatment 1 are \(q_0=0.25\) and \(q_1=0.60\). Suppose the outcome risks under fixed treatment and mediator values are \(r_{00}=0.10\), \(r_{01}=0.30\), \(r_{10}=0.20\), and \(r_{11}=0.50\). Calculate the four stochastic-intervention risks, the direct effect using the treatment-0 mediator distribution, and the indirect effect at treatment 1.

For a binary mediator, \(\psi(t,a)=r_{t0}(1-q_a)+r_{t1}q_a\). Under treatment 0 with the treatment-0 mediator distribution,

$$ \psi(0,0)=0.10(1-0.25)+0.30(0.25) =0.10(0.75)+0.075 =0.150. $$

Under treatment 0 with the treatment-1 mediator distribution,

$$ \psi(0,1)=0.10(1-0.60)+0.30(0.60) =0.040+0.180 =0.220. $$

For treatment 1, the corresponding risks are

$$ \psi(1,0)=0.20(0.75)+0.50(0.25) =0.150+0.125 =0.275, $$
$$ \psi(1,1)=0.20(0.40)+0.50(0.60) =0.080+0.300 =0.380. $$

The direct effect with the mediator drawn from its treatment-0 distribution is \(\operatorname{IDE}(0)=0.275-0.150=0.125\), a 12.5-percentage-point increase in outcome risk under treatment 1 versus treatment 0 with that stochastic mediator intervention held fixed. The indirect effect at treatment 1 is \(\operatorname{IIE}(1)=0.380-0.275=0.105\), a 10.5-percentage-point increase when the mediator draw changes from the treatment-0 to the treatment-1 distribution while treatment is held at 1.

The Reference Level Is Part of the Effect

A direct effect is not fully specified until its mediator-distribution reference is stated. Likewise, an indirect effect is not fully specified until its treatment level is stated. If the outcome response to the mediator differs across treatment levels, the indirect contrast can differ between treatment 0 and treatment 1. If the mediator distributions differ, the direct contrast can also depend on which distribution is held fixed. These differences are features of the defined causal contrasts, not calculation errors.

Worked Example: Effects at Both Reference Levels

In a second hypothetical population, suppose \(q_0=0.20\) and \(q_1=0.70\). Let the outcome risks be \(r_{00}=0.05\), \(r_{01}=0.45\), \(r_{10}=0.30\), and \(r_{11}=0.40\). Calculate the indirect effects at both treatment levels and the direct effects using both mediator-distribution references.

First calculate the risks under treatment 0:

$$ \psi(0,0)=0.05(0.80)+0.45(0.20)=0.040+0.090=0.130, $$
$$ \psi(0,1)=0.05(0.30)+0.45(0.70)=0.015+0.315=0.330. $$

Under treatment 1, the risks are

$$ \psi(1,0)=0.30(0.80)+0.40(0.20)=0.240+0.080=0.320, $$
$$ \psi(1,1)=0.30(0.30)+0.40(0.70)=0.090+0.280=0.370. $$

The indirect effect at treatment 0 is \(\operatorname{IIE}(0)=0.330-0.130=0.200\), or 20.0 percentage points. At treatment 1 it is \(\operatorname{IIE}(1)=0.370-0.320=0.050\), or 5.00 percentage points. The mediator-distribution shift has different consequences at the two treatment levels because the stipulated outcome risks across mediator values differ by treatment.

The direct effects are \(\operatorname{IDE}(0)=0.320-0.130=0.190\), or 19.0 percentage points, when the mediator is drawn from its treatment-0 distribution, and \(\operatorname{IDE}(1)=0.370-0.330=0.040\), or 4.00 percentage points, when it is drawn from its treatment-1 distribution. Thus, reporting only “the direct effect” without its mediator reference would leave the estimand ambiguous.

What a Zero Indirect Effect Can Mean

An indirect effect concerns the change in risk caused by changing the mediator distribution under a specified treatment. It is not simply a measure of whether the mediator is associated with the outcome. For example, an outcome can respond to the mediator, yet the indirect contrast can be zero if the two stochastic interventions use the same mediator distribution. It can also be zero at one treatment level and nonzero at another if the mediator’s effect on outcome risk depends on treatment.

Worked Example: No Indirect Effect at One Treatment Level

Consider a third hypothetical population with \(q_0=0.35\) and \(q_1=0.65\). Suppose \(r_{00}=0.08\), \(r_{01}=0.28\), \(r_{10}=0.25\), and \(r_{11}=0.25\). Calculate the indirect effects at treatment 0 and treatment 1, as well as the direct effect using the treatment-0 mediator distribution.

At treatment 0, the mediator distribution changes the risk:

$$ \psi(0,0)=0.08(0.65)+0.28(0.35) =0.052+0.098 =0.150, $$
$$ \psi(0,1)=0.08(0.35)+0.28(0.65) =0.028+0.182 =0.210. $$

Therefore, \(\operatorname{IIE}(0)=0.210-0.150=0.060\), a 6.00-percentage-point increase in risk. At treatment 1, both mediator values have the same stipulated risk, so

$$ \psi(1,0)=0.25(0.65)+0.25(0.35)=0.250, \qquad \psi(1,1)=0.25(0.35)+0.25(0.65)=0.250. $$

Thus \(\operatorname{IIE}(1)=0.250-0.250=0\) percentage points: changing the mediator draw distribution does not change risk at treatment 1 in this example. The direct effect using the treatment-0 mediator distribution is \(\operatorname{IDE}(0)=0.250-0.150=0.100\), a 10.0-percentage-point increase. Each result follows from the specified risks and intervention; none says that mediator-outcome association alone determines the effect.

Common Mistakes

  • Leaving the intervention unspecified. “The mediator is held fixed” can be unclear when the mediator is stochastic. State whether its draw follows the treatment-0 or treatment-1 population distribution.
  • Swapping the two arguments of \(\psi(t,a)\). The first argument is the treatment used for the outcome response; the second selects the mediator distribution. Keep that order consistent in every calculation.
  • Calling a risk difference a probability. A contrast such as \(0.125\) is a difference of risks, or 12.5 percentage points, not a 12.5% probability that an individual outcome will occur.
  • Assuming an estimand is automatically identified. Writing down \(\psi(t,a)\) defines a causal quantity. It does not show that observed data suffice to estimate it without bias.
  • Assuming one indirect effect applies at every treatment level. Calculate \(\operatorname{IIE}(t)\) at the treatment level named in the question; the result may vary with \(t\).
Key takeaway: Interventional direct and indirect effects compare risks under explicit stochastic mediator interventions. To calculate or interpret one, identify the treatment level, the mediator distribution used for the draw, and the risk contrast being taken.

Check Your Understanding

Use the definitions and weighted-average formula to answer the following.

  1. In \(\psi(0,1)\), which treatment level determines the outcome response, and which treatment level supplies the mediator distribution?
  2. If \(q_0=0.30\), \(q_1=0.60\), \(r_{00}=0.10\), and \(r_{01}=0.30\), calculate \(\psi(0,0)\) and \(\psi(0,1)\).
  3. In words, what does \(\operatorname{IDE}(1)\) compare? What mediator intervention is held fixed?
  4. Can \(\operatorname{IIE}(1)\) be zero even when the mediator changes outcome risk under treatment 0? Explain briefly.
  5. Why does defining an interventional effect not, by itself, establish that it is identifiable from observational data?
Clinical Biostats