Problem
Advertisers often cannot randomize users into ad and no-ad groups, for example when a campaign covers a whole city or country. The usual readout then compares before and after, which mixes the ad effect with trends, seasonality, holidays and competitor actions. A wrong baseline leads to wrong budget decisions. Bolt's marketing teams build the baseline as a prediction of what the metric would have been without ads: a counterfactual.
Example from the article: a campaign runs in City 1 from 1 September, City 2 gets no ads, and the model predicts sales in City 1 from sales in City 2.
Solution in brief
Build the counterfactual from the metric's own history (structural) or from untreated control units (control). Train it only on a period whose relationship to the controls resembles the test period. Choose the test length, the metric and the model, then check the setup by simulating the intervention on a pre-campaign period where no effect should appear.
Questions this case answers
- How to estimate the causal effect of an intervention on one unit when randomization is impossible and the baseline has to be predicted from history and untreated units
- How to validate a counterfactual prediction model before using it to read out an intervention
- How to measure the effect of an ad campaign when users cannot be randomized into ad and no-ad groups?
- How to pick control units (cities, products, OS, language) for a counterfactual of ad performance?
Tools and methods
- Structural counterfactual — predicts the metric from its own trend, seasonality and response to holidays and past interventions.
- Control counterfactual — predicts the treated unit from similar units that get no ads (cities, products, OS, language).
- Placebo check on historical data — simulated intervention on a period without ads, like an A/A test.
- CausalImpact (Google) and CausalPy (PyMC) — Bayesian tools that also give prediction uncertainty.
Google or a one-time email code. No password.