Skip to content
StatsOtter A workspace for causal thinking
Method library WORKFLOW / 014
Research workflow/5 steps

Qini curves: automatic cost-benefit analysis

Source grf — Athey, Tibshirani & Wager
01
The method workspace

Follow the analysis.

Select a node to explore the method

Method mapInput → 5 steps → output
START WITHInput data
ARRIVE ATResults
Read step 01
Inside the methodReasoning, equations & implementation
Step 1 of 5
01
Estimation

[GRF] Causal forest

The core estimate — where the causal quantity itself is computed.

What happens here

Fit the forest and produce per-unit CATEs and AIPW scores.

Formula
\tau(x)=\mathbb{E}\!\left[\,Y(1)-Y(0)\mid X=x\,\right]
The estimator

Causal forest — Honest random forest for heterogeneous treatment effects — CATE for a binary treatment via GRF moment conditions.

Reads fromNot specified Feeds into#2#3
Key code
cf <- causal_forest(X, Y, W)          # Y.hat, W.hat cross-fit
tau.hat <- predict(cf)$predictions    # OOB CATEs
Discussion on this step (0)
StatsOtterDiscussion starter · Editorial note

Before using this step, make its assumptions and its output explicit. A useful peer note explains what you would check, what could go wrong, or what would change your interpretation.

Questions to explore
  1. Which assumption matters most here, and what evidence could challenge it?
  2. What would you check before passing this output to the next step?

Peer discussion

  • Bring your experience, a question, or a different perspective.
02
Data contract

Inputs & data

CATEs for one or more treatment arms, plus per-unit-per-arm costs.

Show data format & exampleHide example

Format — one row per unit. Covariates X, a treatment factor W with K arms, and outcome Y; optionally a per-arm cost.

  X1    X2   W       Y
 0.4  -1.1  armA   3.1
-0.1   0.6  ctrl   1.8
 1.2   0.3  armB   4.0
03
Read the evidence

Results & interpretation

5 figures Workflow discussion 0
01FigureA Qini curve vs random targeting — value gained at each level of spend.
02FigureTOC vs Qini: two views of the same prioritisation, one per-unit, one cumulative.
03FigureA multi-armed Qini — allocating a fixed budget across several competing treatments.
04FigureSingle- vs multi-armed policy value at matched spend.
05FigureThe area between two Qini curves quantifies which policy is better, and by how much.

Figures reproduced from grf — Athey, Tibshirani & Wager — unofficial community showcase; all credit to the original authors.

Context & interpretation

The GRF 'Qini curves' tutorial. Targeting in the real world has a budget and per-unit costs; the maq sister package turns CATEs into a Pareto frontier of expected-gain vs spend so you can pick the operating point honestly. Unofficial summary.

Peer notes

Discuss the workflow (0)

  • No comments yet — start the conversation.
IN THE MARGINS

Peer discussion