# Counterfactual Mean Embeddings

arXiv: https://arxiv.org/abs/1805.08845 · HTML: https://mlsanity.com/paper/1805.08845/

## Key facts

- Cited by 32 papers in the map (data through 14 Oct 2026).
- First posted on arXiv 22 May 2018.

## Built on by (most cited first, 30 of 32)

- [Modeling Causal Mechanisms with Diffusion Models for Interventional and Counterfactual Queries](https://mlsanity.com/paper/2302.00860/) (2023)
- [Sharp Bounds for Generalized Causal Sensitivity Analysis](https://mlsanity.com/paper/2305.16988/) (2023)
- [BayesIMP: Uncertainty Quantification for Causal Data Fusion](https://mlsanity.com/paper/2106.03477/) (2021)
- [Normalizing Flows for Interventional Density Estimation](https://mlsanity.com/paper/2209.06203/) (2022)
- [A Neural Framework for Generalized Causal Sensitivity Analysis](https://mlsanity.com/paper/2311.16026/) (2023)
- [On the Relationship Between Explanation and Prediction: A Causal View](https://mlsanity.com/paper/2212.06925/) (2022)
- [Integral Imprecise Probability Metrics](https://mlsanity.com/paper/2505.16156/) (2025)
- [An Efficient Doubly-Robust Test for the Kernel Treatment Effect](https://mlsanity.com/paper/2304.13237/) (2023)
- [Simplifying debiased inference via automatic differentiation and probabilistic programming](https://mlsanity.com/paper/2405.08675/) (2024)
- [Quantifying Aleatoric Uncertainty of the Treatment Effect: A Novel Orthogonal Learner](https://mlsanity.com/paper/2411.03387/) (2024)
- [A Dictionary of Closed-Form Kernel Mean Embeddings](https://mlsanity.com/paper/2504.18830/) (2025)
- [Feature Selection for Discovering Distributional Treatment Effect Modifiers](https://mlsanity.com/paper/2206.00516/) (2022)
- [Neural-Kernel Conditional Mean Embeddings](https://mlsanity.com/paper/2403.10859/) (2024)
- [An Overview of Causal Inference using Kernel Embeddings](https://mlsanity.com/paper/2410.22754/) (2024)
- [Sequential Kernel Embedding for Mediated and Time-Varying Dose Response Curves](https://mlsanity.com/paper/2111.03950/) (2021)
- [Variable Selection in Maximum Mean Discrepancy for Interpretable Distribution Comparison](https://mlsanity.com/paper/2311.01537/) (2023)
- [Doubly-Robust Estimation of Counterfactual Policy Mean Embeddings](https://mlsanity.com/paper/2506.02793/) (2025)
- [Conditional Distributional Treatment Effects: Doubly Robust Estimation and Testing](https://mlsanity.com/paper/2603.16829/) (2026)
- [Doubly Robust Kernel Statistics for Testing Distributional Treatment Effects](https://mlsanity.com/paper/2212.04922/) (2022)
- [Learning Counterfactual Distributions via Kernel Nearest Neighbors](https://mlsanity.com/paper/2410.13381/) (2024)
- [A Two-armed Bandit Framework for A/B Testing](https://mlsanity.com/paper/2507.18118/) (2025)
- [Kernel Treatment Effects with Adaptively Collected Data](https://mlsanity.com/paper/2510.10245/) (2025)
- [Generalized Kernel Ridge Regression for Causal Inference with Missing-at-Random Sample Selection](https://mlsanity.com/paper/2111.05277/) (2021)
- [Importance Weighting Approach in Kernel Bayes' Rule](https://mlsanity.com/paper/2202.02474/) (2022)
- [Estimating Aleatoric Uncertainty in the Causal Treatment Effect](https://mlsanity.com/paper/2602.08461/) (2026)
- [Nonlinear Causal Discovery via Kernel Anchor Regression](https://mlsanity.com/paper/2210.16775/) (2022)
- [Bayesian Counterfactual Mean Embeddings and Off-Policy Evaluation](https://mlsanity.com/paper/2211.01518/) (2022)
- [A Layered Architecture for Universal Causality](https://mlsanity.com/paper/2212.08981/) (2022)
- [Kernel Quantile Embeddings and Associated Probability Metrics](https://mlsanity.com/paper/2505.20433/) (2025)
- [Performative Learning Theory](https://mlsanity.com/paper/2602.04402/) (2026)

## Abstract (arXiv)

Counterfactual inference has become a ubiquitous tool in online advertisement, recommendation systems, medical diagnosis, and econometrics. Accurate modeling of outcome distributions associated with different interventions -- known as counterfactual distributions -- is crucial for the success of these applications. In this work, we propose to model counterfactual distributions using a novel Hilbert space representation called counterfactual mean embedding (CME). The CME embeds the associated counterfactual distribution into a reproducing kernel Hilbert space (RKHS) endowed with a positive definite kernel, which allows us to perform causal inference over the entire landscape of the counterfactual distribution. Based on this representation, we propose a distributional treatment effect (DTE) that can quantify the causal effect over entire outcome distributions. Our approach is nonparametric as the CME can be estimated under the unconfoundedness assumption from observational data without requiring any parametric assumption about the underlying distributions. We also establish a rate of convergence of the proposed estimator which depends on the smoothness of the conditional mean and the Radon-Nikodym derivative of the underlying marginal distributions. Furthermore, our framework allows for more complex outcomes such as images, sequences, and graphs. Our experimental results on synthetic data and off-policy evaluation tasks demonstrate the advantages of the proposed estimator.
