Heterogeneous Treatment Effect Causal Impact Analysis

Statistics
Introduced by
Brodersen et al. (causal impact framework, 2015); Athey & Imbens (HTE estimation, 2016)
Year
2015-2016
Type
Causal inference / heterogeneous effects estimation
Family
Quasi-experimental / causal inference

What does it do?

Heterogeneous treatment effect causal impact analysis combines the Bayesian structural time-series causal impact model with an estimate of how the treatment effect varies across units or subgroups.

The model first builds a counterfactual forecast of the outcome without the intervention, and the gap between observed and counterfactual outcomes is then examined against unit characteristics. The aim is to show whether an intervention affected some groups more than others, not only to report an average effect.

The intuition behind the method

Standard causal impact analysis asks whether an intervention shifted the overall outcome. The heterogeneous version also asks whether the intervention worked equally for everyone or whether some subgroups responded more or less strongly. A Bayesian structural time-series model is used to construct a counterfactual for what would have happened without the intervention. The gap between actual and counterfactual outcomes is then compared across observed characteristics of units or subgroups, which can reveal variation that an aggregate estimate hides.

History

Brodersen et al. (2015) introduced the Bayesian structural time-series causal impact framework, which estimates the effect of an intervention on a time series using control series as the basis for the counterfactual. Athey and Imbens (2016) proposed recursive partitioning with honest estimation for heterogeneous causal effects in experimental and observational data. Neither cited paper describes combining these two approaches. The combined heterogeneous causal impact procedure described on this page is therefore not documented in those sources and has no established origin in the literature cited here.

When to use it

Use this method when a well-defined intervention affects a time series or panel of units, and you have reason to expect the effect differs across subgroups defined by pre-treatment characteristics such as demographics, geography or baseline outcomes. It requires a pre-intervention window long enough to fit a credible control model, and units with background covariates that allow subgroup effects to be estimated. Do not use it when the pre-intervention series is too short for stable Bayesian estimation, when subgroups are very small, or when subgroups are chosen after seeing the outcomes without multiplicity correction, since these conditions substantially raise the risk of false discoveries.

Limitations and considerations

  • The method needs a pre-intervention window long enough to estimate the trend and any seasonal components. In practice this means covering at least one full seasonal cycle, and the adequacy of the window should be judged from the fit of the model to the pre-intervention data.
  • CATE estimation needs enough units in each subgroup; with thin subgroups the intervals become wide and the subgroup comparison is uninformative.
  • The counterfactual depends on the control covariates. If important predictors of the outcome are omitted, the BSTS forecast is biased, and so is every unit-level effect built on it.
  • Two modelling stages (the BSTS counterfactual and the CATE learner) mean that specification errors in the first carry into the second, and the combined model is costlier to fit and check.
  • Comparisons across subgroups need multiplicity control; without it, apparent differences across many subgroups are easily overreported.

Source conditions do not replace independent scientific review or validation by an analysis engine.

Strengths

  • Subgroup effects are reported separately from the aggregate estimate, so an average close to zero can coexist with a clear effect in one subgroup.
  • The counterfactual is a posterior predictive path, so uncertainty at each post-intervention time is represented directly rather than only through asymptotic approximations.
  • The CATE step can use flexible learners such as causal forests or BART, so subgroup structure does not have to be specified as a fixed linear interaction.
  • It can be applied without a randomised control group when parallel control series are available, although this relies on an assumption that the controls would have tracked the treated series without the intervention, which cannot be checked directly from the data.

Applications

  • Evaluating whether a marketing campaign produced different revenue lifts across customer segments defined by prior purchase behaviour.
  • Assessing regional heterogeneity in the effect of a public health intervention using administrative time-series data.
  • Identifying which product lines responded differently to a platform algorithm change using per-item time series.
  • Estimating subgroup-specific effects of a regulatory change on firms of different sizes or sectors.
  • Personalising policy recommendations by learning which individual characteristics predict a larger causal response.
  • Auditing AI-driven interventions to ensure that benefits are equitably distributed across demographic subgroups.

How it works

How it works

1

A Bayesian structural time-series model is fitted to pre-intervention data. As written in the model formula, it combines a local trend component with a regression term in control covariates x_t. Projecting the fitted model past the intervention date, without the intervention, gives a probabilistic counterfactual path for the outcome.

Formula
y_t = \mu_t + x_t^\top \beta + \varepsilon_t,\quad \mu_t = \mu_{t-1} + \delta_{t-1} + \eta_t
2

At each post-intervention time t, the point-wise effect is the observed outcome minus the counterfactual prediction, as in the formula for the estimated effect. Summing or averaging these point-wise effects gives cumulative or average impact, and the posterior of the counterfactual supplies credible intervals.

Formula
\hat{\alpha}_t = y_t - \hat{y}_t^{(0)}
3

Heterogeneity is addressed by estimating the conditional average treatment effect, the expected effect for units with covariates x. The target quantity does not specify an estimator, so the analyst must state how it is estimated. Candidate approaches include honest recursive partitioning, which Athey and Imbens (2016) develop by using one sample to construct subpopulations and a separate sample to estimate the effect within each. More flexible learners, such as causal forests or Bayesian additive regression trees (BART), can also be applied. The cited sources do not describe applying these learners to the output of a BSTS counterfactual. Unit-level estimates need unit-specific counterfactuals, which the single aggregate path described above does not provide, so a panel or per-unit version of the model is required, and the minimum number of treated units per subgroup has to be chosen by the analyst.

Formula
\hat{\tau}(x_i) = \mathbb{E}[Y_i(1) - Y_i(0) \mid X_i = x_i]
4

Unit-level effect estimates are averaged within predefined or data-driven subgroups, and subgroup averages are compared to see which characteristics moderate the response. The subgroup average shown in the formula is an unweighted mean of unit-level estimates, so it approximates the subgroup's conditional effect only to the extent that those unit-level estimates are valid. Any weighting or residualisation should be stated explicitly. To judge whether effects differ, test the difference between subgroup effects directly, for example with a test of differences in treatment effects across subsets, rather than comparing whether individual subgroup intervals overlap. Overlapping intervals do not show that effects are equal, and a non-significant difference is not evidence that the effects are the same.

Formula
\hat{\tau}_g = \frac{1}{|\mathcal{G}|} \sum_{i \in \mathcal{G}} \hat{\tau}(x_i)
5

Subgroup-level uncertainty requires combining the posterior uncertainty of the Bayesian counterfactual with the sampling uncertainty of the CATE estimator, and a multiplicity adjustment is needed when many subgroups are compared. The cited sources do not set out how these two sources of uncertainty should be combined for subgroup estimates, so subgroup intervals should not be reported until a combination rule has been specified and checked.

Common pitfalls

  • Defining subgroups after looking at post-intervention outcomes inflates false discoveries; subgroups should be fixed from theory before the outcomes are examined.
  • A short pre-intervention window produces an unstable counterfactual, and every subgroup effect inherits that instability.
  • Reporting subgroup point estimates without intervals overstates what the data say about differences between groups.
  • Variation among subgroup estimates partly reflects sampling noise, so it is not the same as real differences in effect; a formal test of the difference is needed before concluding that effects differ.
  • If another intervention reaches only some subgroups, the untreated subgroups' control path may no longer be a valid counterfactual, and subgroup contrasts can reflect those other changes.

Frequently asked questions

How is this different from standard causal impact analysis?

Standard causal impact analysis gives a single aggregate estimate of the intervention effect averaged over all units. The heterogeneous version also estimates how the effect varies across subgroups or individuals, by applying CATE estimators to unit-level impact estimates. This second step is not fully specified in the cited sources, so the estimator, how it is fitted and how unit-level counterfactuals are obtained should be stated explicitly in any analysis.

What CATE estimator should I use alongside the BSTS model?

Honest recursive partitioning (Athey and Imbens, 2016) is the approach documented in the cited sources for estimating heterogeneity from covariates. Causal forests and doubly robust learners can handle many covariates flexibly, and BART is an option where full posterior inference on subgroup effects is wanted. None of these is linked to the BSTS counterfactual in the cited sources, so the choice should be justified on the data and the research question.

How much pre-intervention data do I need?

The pre-intervention span should cover at least one full seasonal cycle so that the trend and seasonal pattern can be estimated. The required length depends on the seasonal pattern and the frequency of the data, so no fixed observation count should be applied across frequencies. A short window produces an unreliable counterfactual, and the fit of the model to the pre-intervention period should be checked before relying on the estimates.

How should I handle multiple subgroup comparisons?

Pre-specify subgroups based on substantive theory before looking at post-intervention data. When many subgroup effects are reported, apply a multiplicity adjustment such as false-discovery-rate control, which is standard practice. Post-hoc subgroup searches without correction can produce spurious findings.

Can I use this without a control time series?

The model can be fitted without covariates, but the counterfactual then rests only on the treated series' own pre-intervention trend and seasonality, which is a weaker basis for attribution. The counterfactual is built from control series or contemporaneous covariates, and including well-chosen controls helps reduce confounding in the counterfactual estimate.

Related methods

Sources

  1. Brodersen, K. H., Gallusser, F., Koehler, J., Remy, N., & Scott, S. L. (2015). Inferring causal impact using Bayesian structural time-series models. Annals of Applied Statistics, 9(1), 247-274.

    Open DOI reference
  2. Athey, S., & Imbens, G. (2016). Recursive partitioning for heterogeneous causal effects. Proceedings of the National Academy of Sciences, 113(27), 7353-7360.

    Open DOI reference