Statistical Calculators › Bayesian Sample Size Methods › Bayesian Sample Size Using Historical Borrowing (Power Prior)
← All Calculators

Bayesian Sample Size Methods

Bayesian Sample Size Using Historical Borrowing (Power Prior)

Determines the minimum current-trial sample size for a single-arm binary endpoint when historical data are incorporated through a power prior. The historical likelihood is downweighted by a user-specified borrowing parameter, and the required sample size is the smallest integer achieving the requested Bayesian power.

Historical Data & Design Assumptions

This calculator uses the conjugate Beta-Binomial power-prior formulation for a single-arm binary endpoint.
a₀ = 0 discards the historical data; a₀ = 1 gives the historical likelihood full weight.
The baseline prior is combined with the discounted historical likelihood. The default Beta(1,1) prior is uniform.

Required Sample Size

Exact discrete calculation for the Beta-Binomial conjugate power-prior design.
Enter the design assumptions and click Calculate Sample Size.

Methodology

The power prior incorporates historical observations by raising their likelihood contribution to a discounting parameter a0. For a binary endpoint, the resulting prior remains conjugate when the baseline prior is Beta. This gives a convenient exact calculation of the posterior distribution and of the Bayesian operating characteristics used for sample-size determination.

Power Prior Construction

Let the historical study contain x0 responses among n0 patients. Starting with a Beta(a, b) baseline prior, the historical likelihood is raised to the power a0. The resulting power prior is:

p(p | D0, a0) ∝ L(p | D0)a₀ × pa−1(1−p)b−1

= Beta(a + a₀x0, b + a₀(n0−x0)).

Thus, for the binary endpoint, a0 acts as a fractional information weight on the historical observations. The historical effective sample size contributed by the likelihood is a0n0.

Current-Trial Posterior

If the new trial enrolls n patients and observes x responses, the posterior distribution is:

p | D0, D, a₀ ~ Beta(a + a₀x0 + x, b + a₀(n0−x0) + n−x).

The calculator declares success for a particular possible current-trial result when the posterior probability that the response rate exceeds the null value reaches the prespecified Bayesian threshold:

P(p > p0 | D0, D, a₀) ≥ 1 − α.

Bayesian Power

For each candidate current-trial sample size n, the calculator evaluates every possible response count x = 0, …, n. Under the specified alternative response rate p1, the probability of observing each count is:

P(X=x | p₁,n) = C(n,x) p₁x(1−p₁)n−x.

Bayesian power is the sum of those binomial probabilities for response counts satisfying the posterior-probability decision rule. The reported sample size is the smallest integer n for which this power is at least the requested target.

Interpretation of the Borrowing Parameter

a₀ = 0  →  no historical borrowing
0 < a₀ < 1  →  partial historical borrowing
a₀ = 1  →  full historical likelihood weight

Increasing a0 does not automatically guarantee a smaller sample size. The effect depends on how the historical response rate relates to the null and alternative assumptions. Historical information that conflicts with the current-trial assumptions can change the operating characteristics in the opposite direction from historical information that supports them.

Scope of This Calculator

This implementation is the conjugate single-arm binary-endpoint special case of power-prior Bayesian sample-size determination. It is designed to make the historical-borrowing calculation transparent and reproducible in the browser. More general power-prior designs—including continuous, survival, two-arm, hierarchical, and simulation-based designs—require model-specific likelihoods and operating-characteristic calculations.

Validation Example

Fixed verification inputs: historical events = 18; historical N = 30; a₀ = 0.50; null rate = 0.40; alternative rate = 0.60; one-sided α = 0.05; target power = 0.80; baseline prior = Beta(1,1).

Power-prior parameters: Beta(1 + 0.5×18, 1 + 0.5×12) = Beta(10, 7).

Expected result: required current-trial N = 12.

Achieved power at N = 12: 0.8417877074.

Check at N = 11: power = 0.7534982576, so N = 11 does not meet the 0.80 target.

References

Ibrahim, J.G., Chen, M.-H., Gwon, Y., & Chen, F. (2015). The power prior: theory and applications. Statistical Science, 30(1), 92–108. The paper develops the power-prior framework for incorporating historical information by discounting its likelihood contribution.

Psioda, M.A. & Ibrahim, J.G. (2019). Bayesian clinical trial design using historical data that inform the treatment effect. Biostatistics, 20(3), 400–415. This paper develops Bayesian sample-size determination using historical data and a partial-borrowing power prior, including calibration of borrowing and Bayesian operating characteristics.

The calculator is also aligned with the Bayesian sample-size / historical-borrowing methodology available in Bayesian sample-size software. The present browser implementation specializes that framework to the analytically tractable Beta-Binomial binary-endpoint case.