← Methods repository
concept

Bayesian Borrowing from Historical / External Controls

A Bayesian approach that constructs an informative prior on the concurrent control arm from historical or real-world external-control data, discounting the borrowed information by its commensurability with the current trial so that the strength of borrowing is data-driven rather than all-or-nothing.

Causal_Inference_Methodbayesian-dynamic-borrowingpower-priorcommensurate-priormeta-analytic-predictive-priorrobust-map-priorexternal-controlprior-effective-sample-sizerare-disease
Methods reference only. Use primary source citations and local policy before applying this in a study protocol, regulatory submission, payer dossier, or clinical decision.

In plain language

When a new drug is tested in a rare disease, there are often too few patients to run a full randomized trial with its own control group. Bayesian borrowing solves this by using data from a past group of similar untreated patients as a stand-in control, then applying a discount so that if the past group turns out to look different from today's patients, the borrowed information counts for less. The key insight is that instead of a binary choice between using old data fully or ignoring it entirely, you get a sliding scale: the more similar the historical and current patients look, the more you borrow; the less similar, the less you borrow.

Bayesian dynamic borrowing

augments the control arm of a current study with information from one or more historical or real-world external controls by encoding that external information as an informative prior, then letting the data decide how much weight that prior actually carries. The shared parameter is the control-arm outcome (e.g., the control event rate, mean, or hazard); the treatment-arm parameter is left vague. The result is a posterior on the treatment contrast that "rents" external control information when the external and concurrent controls agree and "returns" it when they disagree. This is the practical answer to the central question Viele et al. pose — how much should we borrow? — replacing the binary choice between naive pooling and ignoring history with a continuous, pre-specified discount.

Core conceptual / estimand distinction

The estimand is unchanged by borrowing: it remains the comparative treatment effect (difference in means, risk difference/ratio, or hazard ratio) versus a control. What changes is the prior on the control parameter, and the discriminating tuning quantity differs by method: - Power prior (Ibrahim & Chen): raise the historical likelihood to a power a0 in [0,1]. a0 = 1 is full pooling; a0 = 0 ignores history. a0 can be fixed (a deterministic discount, e.g., 0.5) or modeled (a hyperprior on a0 — the "normalized/modified" power prior — letting the data move it). - Commensurate prior (Hobbs et al.): tie the current control parameter to the historical one through a commensurability variance; a large estimated commensurability variance automatically down-weights borrowing under conflict. - Meta-analytic-predictive (MAP) prior (Neuenschwander et al.): treat each historical control as an exchangeable draw from a hierarchical model with between-trial heterogeneity tau, then use the predictive distribution for the new control as the prior. Larger tau ⇒ less borrowing. - Robust MAP (Schmidli et al.): mix the MAP prior with a vague (unit-information) component given weight w (commonly 0.1–0.2). The vague component is an insurance policy: under prior-data conflict the posterior shifts toward it, capping the damage from optimistic borrowing.

The common currency across all four is prior effective sample size (ESS) — how many "extra control patients" the prior is worth. ESS is the number to pre-specify, justify to regulators, and report; an ESS of, say, 40 historical controls in a 60-patient concurrent control arm is a very different claim than an ESS of 5.

Pros, cons, and trade-offs

- vs naive pooling of historical and concurrent controls (Pocock combination): Pooling assumes exact exchangeability; any drift in standard of care, case mix, or outcome ascertainment biases the control estimate and inflates type-I error. Dynamic borrowing keeps the upside (smaller control arm, more patients randomized to the experimental drug) while adaptively discounting under conflict. Cost: more modeling, sensitivity analysis, and operating-characteristic simulation; it can still mislead if conflict is real but small relative to noise (the robust weight cannot detect what the data cannot resolve). - vs frequentist "test-then-pool": A pre-test for historical-vs-current difference, then pool if non-significant, has notoriously poor operating characteristics — the test is underpowered, so it pools precisely when it should not, and the final inference ignores the model-selection step. Bayesian borrowing folds the uncertainty about commensurability into one coherent posterior. Prefer dynamic borrowing over test-then-pool in essentially all cases. - vs propensity-score / IPW external-control adjustment: PS methods target patient-level exchangeability by re-weighting an external cohort to the trial's covariate distribution (an identification strategy); borrowing operates at the summary-parameter level and addresses residual trial-to-trial discrepancy. They are complementary: PS-adjust the external control to match the trial population, then borrow the adjusted control estimate with a discount. Borrowing is not a substitute for confounding control. - Fixed vs modeled a0 / robust vs non-robust: Fixed a0 and non-robust MAP borrow aggressively and have the best power if the prior is right; modeled a0 and robust MAP sacrifice some power for protection against prior-data conflict and far better worst-case type-I error. For confirmatory regulatory work, the robust/dynamic versions are the defensible default.

When to use

Rare diseases, pediatric extrapolation, and oncology settings where a fully concurrent randomized control is infeasible or unethical and high-quality historical/RWD controls exist; designs that reduce (not eliminate) the concurrent control with a Bayesian augmented control; HTA submissions for ultra-rare indications where the alternative is no comparative evidence at all. The FDA 2023 externally controlled trials guidance is the governing regulatory frame.

When NOT to use — and when it is actively misleading or dangerous

- Standard-of-care drift between eras. If supportive care, monitoring intensity, or background therapy improved between the historical period and the current trial, the historical control event rate is biased in a fixed direction. Robust weights damp it but cannot fully correct a systematic shift, and a single historical control gives the heterogeneity model no information to estimate tau — borrowing then becomes near-pooling of a biased control. Do not borrow across a known practice change without an explicit, conservative discount and a tipping-point sensitivity analysis. - Differential outcome ascertainment. Historical/RWD controls with registry-adjudicated endpoints versus a current arm with claims-algorithm or central-read endpoints are not measuring the same thing. Borrowing imports measurement bias. - Case-mix / eligibility shift. Newer cohorts caught by earlier screening, different staging, or changed referral patterns differ in baseline prognosis. Borrow only after PS-matching or eligibility-restricting the external control to the trial criteria. - Differential follow-up or censoring rules. Time-to-event borrowing across cohorts with different censoring or follow-up duration distorts the control hazard. - Manufacturing the answer. Tuning a0 or the robust weight after seeing the trial result to reach significance is indefensible; all borrowing parameters and the prior-data-conflict criterion must be locked in the SAP before unblinding, with pre-specified operating characteristics (type-I error under drift, power, ESS) from simulation.

Data-source operational depth (building the external control)

Borrowing inherits every weakness of the external data it is built from. - Claims (FFS vs MA): A claims external-control arm requires the same continuous-enrollment, washout, and first-event discipline as any claims cohort. Medicare-Advantage-only person-time lacks fee-for-service medical/pharmacy claims, so an "event-free" external control built from MA enrollees can be missingness masquerading as a low event rate — restrict to enrollees with complete A/B/D (or commercial medical+pharmacy) coverage. Endpoints defined by claims algorithms (PPV well below 1) systematically understate events relative to an adjudicated trial endpoint, biasing the borrowed control rate downward and the treatment effect toward harm. Pre-period for covariate and washout measurement must mirror the trial's baseline window. - EHR: Outcomes are encounter-driven; a patient who leaves the system looks event-free. Structured fields are sparse, so severity/case-mix matching to trial eligibility is harder — yet matching is exactly what protects borrowing from case-mix conflict. Prefer linkage to claims to firm up follow-up and capture out-of-system events. - Registry: Strongest for indication, stage/severity, and adjudicated endpoints — the best raw material for an external control — but completeness and enrollment selection vary, and the registry era may predate current standard of care (drift). Link to a death index to firm up survival endpoints. - Linked claims–EHR–registry: The ideal substrate (severity + completeness + adjudicated outcomes + mortality), but linkage selection (only the linkable subset) and date discrepancies across order/fill/service dates must be reconciled before defining the index date and follow-up that feed the borrowed summary.

Worked claims-style example

Confirmatory single-arm trial of a new agent in a rare cancer, n = 70 treated, with no concurrent control; the sponsor proposes a Bayesian external control from a linked claims–registry database (FDA 2023 guidance frame). (1) Eligibility-match the external control to the protocol: age, stage, prior-line, ECOG proxy, and 365 days of continuous A/B/D enrollment before `index_date` (first systemic-therapy claim meeting the trial's inclusion window), excluding MA-only person-time so absence of events is observed, not missing. (2) Harmonize the endpoint: define the external overall-survival/progression endpoint with a validated claims algorithm and report its PPV/sensitivity; if it differs from the trial's adjudicated endpoint, pre-specify a bias adjustment. (3) PS-adjust the external cohort to the trial covariate distribution (overlap weighting on the baseline window). (4) Fit a MAP prior on the adjusted external control survival parameter; because only one external source exists, fix between-trial heterogeneity tau at a conservative value from a comparable disease area rather than estimating it from a single study. (5) Robustify the MAP with a 20% vague mixture component and compute prior ESS (target ESS ≈ 25–35 controls — a fraction of the 70 treated). (6) Pre-specify the prior-data-conflict rule (e.g., posterior weight on the vague component, or a Bayesian p-value comparing observed to predicted control survival). (7) Compute the posterior on the survival contrast and run a tipping-point sensitivity analysis over a0/robust-weight and over a plausible standard-of-care drift adjustment to show the conclusion is not an artifact of optimistic borrowing.

Interpreting the output

From the worked example: historical arm n = 100, r = 28 (28%); power prior a0 = 0.4; ESS = 40 borrowed. Current trial controls n = 20, r = 7 (35%). Blended posterior control rate ≈ (11.2 + 7) / (40 + 20) = 18.2 / 60 ≈ 30.3%. Effective control arm size ≈ 60 (40 borrowed + 20 enrolled).

(1) Formal interpretation. The posterior control rate ≈ 30.3% reflects a weighted compromise between the historical rate (28%) and the current trial rate (35%), with the weights determined by the power prior discount (a0 = 0.4) and sample sizes. The posterior is not a frequentist estimate — it is the probability distribution over the control rate given both data sources and the specified prior. Critically, the ESS of 40 borrowed controls is itself conditional on a0 = 0.4; halving a0 to 0.2 would halve the borrowed ESS and shift the posterior toward the current data. Any trial needed only 20 enrolled controls instead of the ≈ 60 that would give equivalent precision without borrowing — but that sample-size reduction is only valid if the historical and current populations are genuinely exchangeable on all outcome-relevant dimensions.

(2) Practical interpretation. If the historical 28% control rate reflected a lower-acuity population (less severe disease than the current trial), borrowing drags the blended control estimate downward from the observed 35%, artificially inflating the apparent treatment benefit. A decision-maker reviewing a Bayesian-borrowing trial should always examine the prior-data-conflict diagnostic — if the current and historical control rates are discordant (e.g., 35% vs 28%), the robust MAP's vague mixture component should have absorbed much of the borrowed weight, and the tipping-point sensitivity over a0 should show the conclusion holds even at minimal borrowing.

Worked example

Scenario

A sponsor runs a single-arm trial of a new drug in a rare blood cancer: 60 patients receive the drug, and there is no concurrent randomized control group. The sponsor wants to compare the new drug's response rate against a historical control group drawn from a registry. The historical group had 100 patients; 28 of them responded (28%). The current trial enrolls 20 control-arm patients as well (small, to conserve enrollment for the treated arm) and observes 7 responders (35%). The sponsor applies a fixed power prior with a discount weight a0 = 0.4, meaning only 40% of the historical data counts. The question is: how many effective control patients does that borrowed history contribute, and what does the combined control estimate look like?

Dataset

Summary counts feeding the borrowing calculation. Each row represents one data source, not one patient.

sourcepatients_nresponders_rresponse_raterole
historical_registry1002828%borrowed (discounted by a0)
current_trial_control20735%full weight (a0 = 1.0)

Steps

  • Step 1 - Calculate borrowed effective sample size: multiply the historical group size by the discount weight. ESS = 100 x 0.4 = 40. The prior counts as 40 phantom control patients.

  • Step 2 - Calculate borrowed events: apply the same discount to the historical event count. Borrowed events = 28 x 0.4 = 11.2.

  • Step 3 - Pool the borrowed information with the current control data: combined pseudo-events = 11.2 + 7 = 18.2; combined pseudo-patients = 40 + 20 = 60.

  • Step 4 - Compute the posterior (blended) control response rate: 18.2 / 60 = 0.303, or about 30%.

  • Step 5 - Interpret the result: the blended rate (30%) sits between the historical rate (28%) and the current small-sample rate (35%), pulled toward the historical data in proportion to how much was borrowed. Because the two rates were close, borrowing is reasonable; if they had differed by 15 percentage points or more, the sponsor would need a more conservative discount or a robust design.

Result

With a0 = 0.4, the 100-patient historical registry contributes an ESS of 40 phantom controls. Combined with 20 actual trial controls, the effective control arm is 60 patients (40 borrowed + 20 real), yielding a blended response rate of 18.2 / 60 = 0.303 (30%). The trial needed only 20 enrolled controls instead of the ~60 that would have been required without borrowing, but this efficiency comes with a risk: if the historical 28% rate reflects older, less-fit patients while the current trial enrolled healthier patients (hence the observed 35%), the borrowed prior drags the control estimate downward and makes the new drug look better than it truly is.

Runnable example

r implementation

Robust MAP prior for a binary control endpoint using RBesT (Schmidli et al.'s package), the canonical implementation. Required input - one row per historical/external control cohort with aggregate counts: hist : study (chr), n (int, control patients), r...

library(RBesT)

# Aggregate historical/external control cohorts (binary endpoint).
hist <- data.frame(
  study = c("registry_A", "registry_B", "claims_C"),
  n     = c(120L, 95L, 140L),
  r     = c(34L,  21L,  41L)   # events among external controls
)

# (1) Hierarchical MAP across cohorts; tau prior encodes between-trial heterogeneity.
set.seed(1)
map_mc <- gMAP(cbind(r, n - r) ~ 1 | study, data = hist,
               family = binomial,
               tau.dist = "HalfNormal", tau.prior = 0.5,   # heterogeneity scale (logit)
               beta.prior = 2)

# (2) Parametric Beta-mixture approximation of the MAP prior.
map_prior <- automixfit(map_mc)

# (3) Robustify: add a weakly-informative unit-information component (insurance against conflict).
rob_prior <- robustify(map_prior, weight = 0.2, mean = 0.5)  # 20% vague weight

# (4) Prior effective sample size = how many "extra control patients" we are borrowing.
cat("Prior ESS (robust MAP):", round(ess(rob_prior), 1), "control patients\n")

# (5) Update with the CURRENT trial control arm (e.g., 18 events / 30 controls).
post_ctrl <- postmix(rob_prior, r = 18, n = 30)

# Treatment arm: vague prior updated with current treated arm (e.g., 9 events / 70 treated).
post_trt  <- postmix(mixbeta(c(1, 0.5, 0.5)), r = 9, n = 70)

# Posterior on the risk difference (treated - control) by Monte Carlo.
draws_c <- rmix(post_ctrl, 1e5); draws_t <- rmix(post_trt, 1e5)
rd <- draws_t - draws_c
cat(sprintf("Posterior risk difference: %.3f (95%% CrI %.3f, %.3f)\n",
            mean(rd), quantile(rd, .025), quantile(rd, .975)))
cat("P(treated rate < control rate):", mean(rd < 0), "\n")
python implementation

Power prior for a binary control endpoint in PyMC, with the discount a0 as a modeled hyperparameter (normalized power prior) so the data govern borrowing. Inputs are aggregate counts: hist_n, hist_r : external-control patients and events (e.g.,...

import numpy as np
import pymc as pm
import pytensor.tensor as pt
import arviz as az

hist_n, hist_r = 355, 96       # pooled external-control patients / events
cur_ctrl_n, cur_ctrl_r = 30, 18
cur_trt_n,  cur_trt_r  = 70, 9

with pm.Model() as m:
    # Shared control event probability; vague treated probability. Beta(1,1) base prior on p_ctrl.
    p_ctrl = pm.Beta("p_ctrl", 1.0, 1.0)
    p_trt  = pm.Beta("p_trt", 1.0, 1.0)

    # Borrowing weight a0 in [0,1], modeled so the data govern borrowing.
    a0 = pm.Beta("a0", 1.0, 1.0)

    # Historical control binomial log-likelihood raised to power a0.
    hist_loglik = pm.logp(pm.Binomial.dist(n=hist_n, p=p_ctrl), hist_r)
    pm.Potential("power_prior", a0 * hist_loglik)

    # NORMALIZED power prior: subtract log of the Beta normalizing constant C(a0) so the joint is proper.
    # With Beta(1,1) on p_ctrl, the a0-scaled posterior kernel integrates to B(a0*r+1, a0*(n-r)+1).
    log_norm = (pt.gammaln(a0 * hist_r + 1.0)
                + pt.gammaln(a0 * (hist_n - hist_r) + 1.0)
                - pt.gammaln(a0 * hist_n + 2.0))
    pm.Potential("power_prior_norm", -log_norm)

    # Current data: control and treated arms (full weight).
    pm.Binomial("cur_ctrl", n=cur_ctrl_n, p=p_ctrl, observed=cur_ctrl_r)
    pm.Binomial("cur_trt",  n=cur_trt_n,  p=p_trt,  observed=cur_trt_r)

    rd = pm.Deterministic("risk_diff", p_trt - p_ctrl)
    idata = pm.sample(2000, tune=2000, target_accept=0.95, random_seed=1)

a0_mean = float(idata.posterior["a0"].mean())
print(f"Posterior mean a0 (realized borrowing): {a0_mean:.2f}")
print(f"Approx borrowed ESS: {a0_mean * hist_n:.0f} external controls")
print(az.summary(idata, var_names=["p_ctrl", "p_trt", "risk_diff", "a0"], hdi_prob=0.95))
rd_draws = idata.posterior["risk_diff"].values.ravel()
print(f"P(treated rate < control rate): {(rd_draws < 0).mean():.3f}")