Difference-in-differences with a mediator
Listen
Radio episode about this paper
Transcript
Introduction to the show: ident: Economics. The day in economics: theory, mechanisms and the evidence beneath them.
Ruth: We're looking at the paper: "Difference-in-differences with a mediator".
Warren: Here's the gist of the paper. Difference-in-differences with a mediator advances mediation analysis within the difference-in-differences framework to identify natural indirect, direct, and total effects under specific assumptions The paper demonstrates that natural indirect, direct, and total effects are identifiable in the treated group under a mediator-adjusted parallel trends assumption and additional conditions Framework of Estimands The estimands considered are the natural indirect effect (NIE), the natural direct effect (NDE), and the total effect.
Ruth: The total effect is defined as τ = E
Y1(1) − Y1(0) G = 1: = E
Y1(1, M(1)) − Y1(0, M(0)) G = 1: The NIE is defined by switching the treatment associated with the mediator as τIE = E
Y1(0, M(1)) − Y1(0, M(0)) G = 1: The NDE is defined by switching the treatment associated with the outcome as τDE = E
Y1(1, M(1)) − Y1(0, M(1)) G = 1: Identification Assumptions The identification of these effects in a two-period difference-in-differences setting relies on several key assumptions Assumption 2 requires that the time trend in untreated potential outcomes is identical across groups conditional on baseline covariates and the effect on the mediator, avoiding potential collider bias Assumption 3, sequential ignorability, requires no unmeasured confounding between treatment assignment and the mediator, and no unmeasured confounding between the post-treatment mediator M(1) and the change in potential outcomes Estimation Methodology The paper derives efficient influence functions (EIF) for these estimands using semiparametric theory The EIFs are derived by finding a unique regular and asymptotically linear estimator whose influence function is in the tangent space of the model space The estimators constructed are multiply robust and locally nonparametrically efficient, consistent if either two of the propensity score, mediator distribution, and the outcome regression models are correctly specified Application to Job Corps Study Applying this methodology to data from the Job Corps Study reveals that job training significantly increases both short-term and long-term earnings after controlling for the indirect effect through the proportion of weeks employed The estimated total effect is 0.0609 (s.e.
Warren: 0.0623, 95%CI
-0.0612, 0.183: ) The natural indirect effect is estimated at-0.0447 (s.e.
Ruth: 0.0436, 95%CI
-0.1302, 0.0408: ), indicating that joining the training program slightly reduces earnings by reducing work time The natural direct effect is estimated at 0.1055 (s.e.
Title and authors: Ruth: So, to kick things off, we’re talking about this paper titled "Difference-in-differences with a mediator," authored by Yuhao Deng, Haoyu Wei, and Zhongzhe Ouyang. This is the full name of the work we’re analyzing today.
Warren: I see the title is very descriptive; it immediately tells you they are using a difference-in-differences approach and focusing on how a mediator fits into that framework to untangle treatment effects.
Iris: It’s important because, as we know, standard causal mediation analysis often fails in observational studies because of confounding between the treatment assignment and the potential outcomes.
Ruth: Precisely. This paper suggests that by using this difference-in-differences setup under specific conditions—like a mediator-adjusted parallel trends assumption—they can make the natural indirect, direct, and total effects identifiable in the treated group.
Warren: They aren't just suggesting it; they are providing methods to estimate these three distinct effects: the natural indirect effect, the natural direct effect, and the total effect.
Iris: The main takeaway is that these effects are estimable when you satisfy specific identification assumptions and then use a sophisticated estimation technique to get efficient results.
Ruth: So it’s about making mediation analysis practical for real-world observational data by providing a robust path from data to those key causal quantities.
The paper's summary: Warren: They summarize the paper by saying that they advance mediation analysis within the difference-in-differences framework, showing how to identify natural indirect, direct, and total effects under those specific identification assumptions.
Ruth: They focus on defining these estimands clearly: the total effect is defined as E of Y one (one) minus Y one (zero) conditional on G equals one, which is switching the treatment for both outcome and mediator at time one.
Iris: Then they define the natural indirect effect by switching the treatment associated with the mediator, which is E of Y one (zero) minus Y one (zero) conditional on G equals one.
Warren: And then they define the natural direct effect by switching the treatment associated with the outcome, which is E of Y one (one) minus Y one (one) conditional on G equals one.
Ruth: They also emphasize that to do this work properly, you need those identification assumptions to hold—specifically assumption two about parallel trends and assumption three about sequential ignorability.
Iris: And they move beyond just proposing the setup; they derive efficient influence functions for these estimands using semiparametric theory.
Warren: This is where it gets technical, because they are finding estimators that are multiply robust and locally nonparametrically efficient, which means the consistency depends on correctly specifying either two of their models.
Ruth: So it’s not just a one-off estimate; it’s a whole methodology for building an estimator that has strong guarantees about its performance under model misspecification.
The paper's improvements: Iris: One major improvement they suggest is the derivation of these efficient influence functions using semiparametric theory, which gives you a lower bound for the variance of regular and asymptotically linear estimators.
Warren: That’s what allows them to construct estimators that are consistent if either two of their propensity score, mediator distribution, and outcome regression models are correctly specified.
Ruth: They also point out that for continuous mediators, they can use kernel smoothing to approximate these efficient influence functions to get nonparametric efficiency bounds under specific regularity conditions on the working models.
Iris: That nonparametric efficiency is a big step because it allows them to handle continuous mediator data in a flexible way without needing those strong assumptions about the functional form of the relationship.
Warren: They also mention that they derive the controlled direct effect at a specific mediator value using an efficient influence function derived from either a point mass contamination path or a kernel convolution.
Ruth: So this means when you have discrete data, it’s efficient; when you have continuous data, it gets very close to being the most efficient estimate possible under the given constraints.
Conclusion: Ruth: To wrap up, the authors of "Difference-in-differences with a mediator" show that this framework addresses challenges in observational studies by providing estimators that are multiply robust and nonparametrically efficient.
Warren: The analysis highlights that while the natural indirect effect is insignificant, the natural direct effect is significant at zero point one zero five five.
Iris: And the controlled direct effect suggests a positive long-term impact conditional on employment across a broad range of employment levels for both continuous and ordinal mediators.
Ruth: So, they conclude that for both continuous and ordinal mediators, the estimated controlled direct effect is significantly positive across all those employment levels they tested.
Warren: It’s an important tool because it shows that we can get a more reliable estimate of the direct effect when you're dealing with complex mediation pathways in observational settings.
Iris: The main caveat they put forward is that the identification relies heavily on those specific parallel trends and sequential ignorability assumptions being satisfied.
Ruth: Exactly, so while the tools are powerful, their practical use depends on how well we can verify those underlying assumptions in our specific datasets.
Fred Hutchinson Cancer Center · University of California San Diego · Guangzhou University
econ.EM
Submitted: 2026-04-27
Updated: 2026-11-08
License: http://arxiv.org/licenses/nonexclusive-distrib/1.0/
Importance score: 82/100
The gist: Difference-in-differences with a mediator advances mediation analysis within the difference-in-differences framework to identify natural indirect, direct…
Key concepts
- Natural Indirect Effect (NIE)
- This measures the effect of treatment on the outcome that occurs specifically through its influence on a mediator. It is calculated by switching the treatment status associated with the mediator while holding other factors constant. In this study, it showed joining training slightly reduces earnings by reducing work time.
- Natural Direct Effect (NDE)
- This represents the direct effect of treatment on the outcome, controlling for the effect that goes through the mediator. It is calculated by switching the treatment status associated with the primary outcome while holding other factors and the mediator constant. The study found this effect was significant, suggesting a direct positive impact on earnings.
- Difference-in-Differences (DiD) Framework
- This statistical method is used to estimate causal effects in observational studies by comparing changes over time between a treated group and a control group. When combined with mediator analysis, it allows researchers to decompose the total effect into indirect and direct components under specific parallel trends assumptions.
- Controlled Direct Effect (CDE)
- The CDE measures the direct effect of treatment on the outcome at a specific level of the mediator. By analyzing this across different employment levels, the study found that training enhances earnings capacity in the long run, conditional on how much work time is reduced.
Terminology
Summary
Difference-in-differences with a mediator advances mediation analysis within the difference-in-differences framework to identify natural indirect, direct, and total effects under specific assumptions The paper demonstrates that natural indirect, direct, and total effects are identifiable in the treated group under a mediator-adjusted parallel trends assumption and additional conditions
Framework of Estimands
The estimands considered are the natural indirect effect (NIE), the natural direct effect (NDE), and the total effect. The total effect is defined as τ = E[Y1(1) − Y1(0) G = 1] = E[Y1(1, M(1)) − Y1(0, M(0)) G = 1] The NIE is defined by switching the treatment associated with the mediator as τIE = E[Y1(0, M(1)) − Y1(0, M(0)) G = 1] The NDE is defined by switching the treatment associated with the outcome as τDE = E[Y1(1, M(1)) − Y1(0, M(1)) G = 1]
Identification Assumptions
The identification of these effects in a two-period difference-in-differences setting relies on several key assumptions Assumption 2 requires that the time trend in untreated potential outcomes is identical across groups conditional on baseline covariates and the effect on the mediator, avoiding potential collider bias Assumption 3, sequential ignorability, requires no unmeasured confounding between treatment assignment and the mediator, and no unmeasured confounding between the post-treatment mediator M(1) and the change in potential outcomes
Estimation Methodology
The paper derives efficient influence functions (EIF) for these estimands using semiparametric theory The EIFs are derived by finding a unique regular and asymptotically linear estimator whose influence function is in the tangent space of the model space The estimators constructed are multiply robust and locally nonparametrically efficient, consistent if either two of the propensity score, mediator distribution, and the outcome regression models are correctly specified
Application to Job Corps Study
Applying this methodology to data from the Job Corps Study reveals that job training significantly increases both short-term and long-term earnings after controlling for the indirect effect through the proportion of weeks employed The estimated total effect is 0.0609 (s.e. 0.0623, 95%CI [-0.0612, 0.183]) The natural indirect effect is estimated at-0. p. 00447 (s.e. 0.0436, 95%CI [-0.1302, 0.0408]), indicating that joining the training program slightly reduces earnings by reducing work time The natural direct effect is estimated at 0. p. 21055 (s.e. 0.0445, 95%CI [0.0183, 0.1927]), indicating that joining the training program significantly leads to higher earnings if the participant had not reduced work time
Controlled Effects Analysis
The controlled direct effect (CDE) τDE(m) is defined as E[Y1(1, m) − Y1(0, m) G = 1] The CDE curve shows a positive direct effect of training across a broad range of employment levels for both continuous and ordinal mediators This pattern indicates that in the longer run, the Job Corps program enhances earnings capacity conditional on employment
Conclusion
The proposed framework addresses challenges in observational studies by considering difference-in-differences and provides estimators that are multiply robust and nonparametrically efficient The analysis shows that while the natural indirect effect is insignificant, the natural direct effect is significant, and the controlled direct effect suggests a positive long-term impact conditional on employment, The paper concludes that for both continuous and ordinal mediators, the estimated CDE is significantly positive across a broad range of employment levels.
--- Page 1 ---
Difference-in-differences with a mediator advances mediation analysis within the difference-in-differences framework to identify natural indirect, direct, and total effects under specific assumptions The paper demonstrates that natural indirect, direct, and total effects are identifiable in the treated group under a mediator-adjusted parallel trends assumption and additional conditions
The proposed framework addresses challenges in observational studies by considering difference-in-differences and provides estimators that are multiply robust and nonparametrically efficient The analysis shows that while the natural indirect effect is insignificant, the natural direct effect is significant, and the controlled direct effect suggests a positive long-term impact conditional on employment,
--- Page 2 ---
1 Introduction
In the economic and health sciences, studying the mechanisms by which treatment affects outcomes has been both interesting and challenging. The treatment can exert its effects either directly on the outcome or indirectly through a mediator Mediation analysis was initially proposed within linear models (Baron and Kenny, 1986) Later, mediation analysis was formalized using potential outcomes, in which the mediator is a potential outcome of the treatment and the primary outcome is a potential outcome of the treatment and the mediator (Rubin, 2004; Goetgeluk et al. p. 1 p. 1 p. 1, 2008) By controlling the mediator at the natural level, the total effect is decomposed into a natural indirect and a natural direct effect Identifiability assumptions have been proposed to identify the natural indirect and direct effects (Imai et al. p. 1 p. 1 p. 1, 2010,?) In general, mediation analysis methods require that the treatment assignment, mediator, and primary outcome be unconfounded, which is a stringent condition in observational studies
In our setting, treatment may not be randomized so we adopt the treated group G = 1 as the target population to minimize identification requirements The total effect is τ = E[Y1(1) − Y1(0) G = 1] = E[Y1(1, M(1)) − Y1(0, M(0)) G = 1] By switching the treatment associated with the mediator, we define the natural indirect effect (NIE) as τIE = E[Y1(0, M(1)) − Y1(0, M(0)) G = 1] By switching the treatment associated with the outcome, we define the natural direct effect (NDE) as τDE = E[Y1(1, M(1)) − Y1(0, M(1)) G = 1]
To identify the natural indirect, direct, and total effects for the treated group, we adopt a difference-in-differences framework and impose several assumptions Assumption 2 extends the standard parallel trends assumption to accommodate a mediator, requiring that conditional on baseline covariates and the effect on the mediator, the time trend in untreated potential outcomes is identical across groups Assumption 3, sequential ignorability, excludes pairwise unmeasured confounding between treatment, mediator, and outcome
To improve robustness and efficiency, we derive the efficient influence function (EIF) of τ (g, g∗) using semiparametric theory The EIF provides a lower bound for the variance of regular and asymptotically linear estimators The proposed estimators are consistent if either two of the propensity score, mediator distribution, and the outcome regression models are correctly specified
--- Page 3 ---
1 Introduction
In the economic and health sciences, studying the mechanisms by which treatment affects outcomes has been both interesting and challenging. The treatment can exert its effects either directly on the outcome or indirectly through a mediator Mediation analysis was initially proposed within linear models (Baron and Kenny, 1986) Later, mediation analysis was formalized using potential outcomes, in which the mediator is a potential outcome of the treatment and the primary outcome is a potential outcome of the treatment and the mediator (Rubin, 2004; Goetgeluk et al., 2008) By controlling the mediator at the natural level, the total effect is decomposed into a natural indirect and a natural direct effect Identifiability assumptions have been proposed to identify the natural indirect and direct effects (Imai et al., 2010,?) In general, mediation analysis methods require that the treatment assignment, mediator, and primary outcome be unconfounded, which is a stringent condition in observational studies
--- Page 4 ---
1 Introduction
In the economic and health sciences, studying the mechanisms by which treatment affects outcomes has been both interesting and challenging. The treatment can exert its effects either directly on the outcome or indirectly through a mediator Mediation analysis was initially proposed within linear models (Baron and Kenny, 1986) Later, mediation analysis was formalized using potential outcomes, in which the mediator is a potential outcome of the treatment and the primary outcome is a potential outcome of the treatment and the mediator (Rubin, 2004; Goetgeluk et al., 2008) By controlling the mediator at the natural level, the total effect is decomposed into a natural indirect and a natural direct effect Identifiability assumptions have been proposed to identify the natural indirect and direct effects (Imai et al., 2010,?
Green — the paper says it, and the page is printed. Red — no passage carries it, so treat that sentence as unverified. The same check runs on your own text: check a summary against its source, $5.
Improvements for AI systems
-
Improved Causal Mediation Analysis in Observational Settings: The system can now perform causal mediation analysis within a difference-in-differences framework, demonstrating that natural indirect, direct, and total effects are identifiable under specific assumptions like a mediator-adjusted parallel trends assumption.
-
Efficient Influence Function Derivation: The AI can derive efficient influence functions for the natural and total effects using semiparametric theory to construct estimators that are both robust to nuisance model misspecification and asymptotically efficient.
-
Multiple Robust Estimation: The system can construct multiply robust estimators where consistency is achieved if either two of the propensity score, mediator distribution, and outcome regression models are correctly specified, offering a stronger guarantee against model misspecification than single robustness.
-
Nonparametric Efficiency in Continuous Mediators: For continuous mediators, the AI can employ kernel smoothing to approximate efficient influence functions and achieve nonparametric efficiency bounds for the estimators under specific regularity conditions on the working models.
-
Controlled Effect Estimation: The system can estimate controlled direct effects at a specific mediator value by utilizing an efficient influence function derived from a point mass contamination path or kernel convolution, providing estimates that are asymptotically most efficient when the mediator is discrete and near-optimal in rate when continuous.
Sources
Related papers
- Stationarity with Occasionally Binding Constraints
- Backtesting High-Dimensional Expected Shortfall
- Higher-Order Neyman Orthogonality in Moment-Condition Models
- Online Bayesian Inference for a Dirichlet Process Mixture of Binary Logit Models
- Debiased Conditional Independence Tests for Causal Effects
- Sharp Testable Implications of Encouragement Designs