Skip to contents

The asymmetry is deliberate. Observational rows sharpen the outcome regression, because a wrong Q is repaired by the targeting step; they do not enter the clever covariate, because their treatment mechanism is unknown and a wrong g would discard the one thing the trial guarantees. So g is the trial's own empirical randomisation probability and H = I(trial)/P(trial) * [D/g - (1 - D)/(1 - g)], making the target the ATE in the TRIAL population. Biased observational rows cost efficiency, not consistency.

Usage

Tmlrct(y_rct, y_obs, D, X)

Arguments

y_rct

Trial outcomes.

y_obs

Observational outcomes.

D

Binary treatment, trial rows first.

X

Covariates, trial rows first.

Value

List with estimate, se, eps, g_rct, n_rct, n_obs, n.

Details

Rows are stacked trial-first: D and X must have length(y_rct) + length(y_obs) rows in that order.

References

Athey, S., Chetty, R., Imbens, G. W. & Kang, H. (2025). Review of Economic Studies 93(4):2284-2312; van der Laan, M. J. & Rubin, D. (2006). IJB 2(1):11.

Examples

set.seed(6)
n1 <- 150; n2 <- 300
X <- matrix(rnorm(n1 + n2), ncol = 1)
D <- c(rbinom(n1, 1, 0.5), rbinom(n2, 1, plogis(X[(n1 + 1):(n1 + n2)])))
y <- 1 + D + X[, 1] + rnorm(n1 + n2)
Tmlrct(y_rct = y[1:n1], y_obs = y[-(1:n1)], D = D, X = X)$estimate
#> [1] 1.063645