Tutorials › Bayesian Clinical Trials › Worked Beta-Binomial Monitoring Calculations

Phase 2 Single-Arm Monitoring · Tutorial 597 of 696

Worked Beta-Binomial Monitoring Calculations

Learn to calculate and interpret the predictive probability of reaching a fixed binary-response success target from interim trial data.

Intermediate 12 min read

What You'll Learn

  • Translate a fixed terminal response requirement into the number of additional responses needed.
  • Calculate Beta-Binomial predictive probabilities from the interim posterior and remaining sample size.
  • Check the predictive tail against its possible range, including cases with probability zero or one.
  • Use a recurrence to calculate predictive masses and verify arithmetic.
  • Distinguish predictive probability from a posterior probability about the response rate and from a decision threshold.
  • Recognize how model assumptions and small remaining sample sizes affect interpretation.

From Interim Data to a Terminal Target

In a single-arm trial with a binary endpoint, interim monitoring often asks a concrete planning question: given the responses observed so far, how likely is the trial to finish with enough responses to meet its prespecified terminal success rule? The answer is a predictive probability. It averages over uncertainty about the response rate and the outcomes that have not yet been observed.

This tutorial works through that calculation for several hypothetical trials. The terminal success rule is held fixed within each example; the focus is translating the rule into a future-count tail, computing that tail, and interpreting it. A predictive probability is not, by itself, a stopping instruction. A protocol needs a separate decision criterion to turn a calculated probability into an action.

Definition: Suppose the response probability is \(\theta\), with prior distribution \(\theta\sim\mathrm{Beta}(a,b)\), where \(a,b>0\). At an interim analysis, \(x\) responses are observed among \(n\) participants. If the trial has a fixed total sample size \(N\), let \(M=N-n\) be the number of participants still to be observed, and let \(Y\) be their number of responses. For a terminal rule requiring at least \(r\) total responses, the predictive probability of terminal success is $$ \Pr(x+Y\geq r\mid x,n)=\Pr(Y\geq r-x\mid x,n). $$

The calculation assumes that each participant has a binary response outcome, the response probability is constant across participants, and outcomes are conditionally independent given \(\theta\). The prior is Beta, the total sample size and terminal response requirement are fixed, and the \(n\) interim outcomes are observed without unresolved outcomes. These assumptions make the remaining outcomes exchangeable after integrating over uncertainty in \(\theta\). If response probabilities differ systematically by time, subgroup, or treatment exposure, this simple model may not be adequate.

The Calculation in a Usable Form

After observing \(x\) responses in \(n\) participants, the posterior distribution is \(\theta\mid x,n\sim\mathrm{Beta}(A,B)\), where \(A=a+x\) and \(B=b+n-x\). Conditional on \(\theta\), the future count has a binomial distribution with \(M\) trials. Integrating that binomial probability over the posterior gives the Beta-Binomial predictive mass:

$$ \Pr(Y=y\mid x,n) =\binom{M}{y}\frac{\mathrm{B}(A+y,B+M-y)}{\mathrm{B}(A,B)}, \qquad y=0,1,\ldots,M. $$

Here \(\mathrm{B}(\cdot,\cdot)\) is the beta function. The predictive probability of terminal success is the sum of the masses for all future counts that meet the rule. Importantly, the count must be within the possible range from zero to \(M\).

$$ \Pr(x+Y\geq r\mid x,n) = \begin{cases} 1, & r-x\leq 0,\\[4pt] \displaystyle\sum_{y=r-x}^{M}\binom{M}{y} \frac{\mathrm{B}(A+y,B+M-y)}{\mathrm{B}(A,B)},& 0<r-x\leq M,\\[10pt] 0, & r-x>M. \end{cases} $$

When the required future count lies inside the possible range, it can be convenient to start with the probability of zero future responses and build the other masses by recurrence. If \(p_y=\Pr(Y=y\mid x,n)\), then

$$ p_0=\frac{\mathrm{B}(A,B+M)}{\mathrm{B}(A,B)},\qquad \frac{p_{y+1}}{p_y} = \frac{M-y}{y+1}\frac{A+y}{B+M-y-1}, \quad y=0,\ldots,M-1. $$

The recurrence follows by dividing the Beta-Binomial mass at \(y+1\) by the mass at \(y\), using \(\binom{M}{y+1}/\binom{M}{y}=(M-y)/(y+1)\) and the beta-function identity \(\mathrm{B}(u+1,v-1)/\mathrm{B}(u,v)=u/(v-1)\). It provides a compact arithmetic check: the masses should be nonnegative and sum to one, up to rounding.

1
Record the interim state.
Write \(x\), \(n\), and the fixed total \(N\); calculate \(M=N-n\).
2
Update the prior.
Set \(A=a+x\) and \(B=b+n-x\) for the Beta posterior.
3
Translate the terminal rule.
Calculate \(r-x\), then check whether the required future count is below zero, within \(0,\ldots,M\), or above \(M\).
4
Sum and interpret.
Sum the relevant predictive masses and describe the result as a probability of meeting the fixed terminal rule, conditional on the model and interim data.

Worked Calculations

Worked Example: A High Terminal Target With Five Participants Remaining

Suppose a hypothetical trial uses a \(\mathrm{Beta}(1,1)\) prior. At an interim analysis, 5 of 15 participants have responded. The fixed total sample size is \(N=20\), and terminal success requires at least \(r=9\) responses. Calculate the predictive probability of terminal success.

The posterior is \(\mathrm{Beta}(1+5,1+15-5)=\mathrm{Beta}(6,11)\), and \(M=20-15=5\). The trial needs \(9-5=4\) more responses, so success occurs if \(Y=4\) or \(Y=5\). The requirement is within the possible range \(0,\ldots,5\).

For this posterior, the probability of zero future responses is $$ p_0=\frac{11\cdot12\cdot13\cdot14\cdot15}{17\cdot18\cdot19\cdot20\cdot21} \approx 0.1476. $$ Using the recurrence, the successive masses are \(p_1=2p_0\), \(p_2=p_1\), \(p_3=(8/13)p_2\), \(p_4=(3/8)p_3\), and \(p_5=(2/11)p_4\). Thus \(p_4\approx0.06811\) and \(p_5\approx0.01238\), giving $$ \Pr(Y\geq4\mid x=5,n=15)=p_4+p_5\approx0.06811145+0.01238390\approx0.08050. $$

Under this model and these interim data, the predictive probability of finishing with at least 9 responses is about 8.05%. The tail starts at 4 because the target is 9 and 5 responses are already observed. If the target instead required 8 responses, the future tail would start at 3 and would include \(p_3\) as well; the terminal rule must be translated exactly before summing.

Worked Example: A Mid-Range Target With Three Participants Remaining

Consider another hypothetical trial with a \(\mathrm{Beta}(1,1)\) prior. Four responses have been observed among 7 participants. The total sample size is \(N=10\), and the terminal rule requires at least 6 responses. Find the predictive probability of success.

The posterior is \(\mathrm{Beta}(5,4)\), and \(M=10-7=3\). The future count must be at least \(6-4=2\), so the relevant masses are \(p_2\) and \(p_3\).

Starting from zero future responses, $$ p_0=\frac{4\cdot5\cdot6}{9\cdot10\cdot11} =\frac{120}{990}\approx0.1212. $$ The recurrence gives \(p_1/p_0=3(5)/6=2.5\), so \(p_1\approx0.3030\). It then gives \(p_2/p_1=(2/2)(6/5)=6/5\), so \(p_2=4/11\approx0.3636\). Finally, \(p_3/p_2=(1/3)(7/4)=7/12\), so \(p_3=7/33\approx0.2121\). Therefore, $$ \Pr(Y\geq2\mid x=4,n=7)=p_2+p_3=\frac{4}{11}+\frac{7}{33}=\frac{19}{33}\approx0.5758. $$

The predictive probability is about 57.58%. This is the probability of reaching at least 6 total responses in the planned 10 participants, conditional on the stated model and observed data. It is not the posterior probability that \(\theta\) exceeds a particular response-rate threshold; that would be a different probability statement.

Worked Example: A Symmetric Interim State

In a third hypothetical trial, the prior is \(\mathrm{Beta}(1,1)\), and 2 of the first 4 participants respond. The trial plans to enroll \(N=8\) participants and defines terminal success as at least \(r=5\) responses. Calculate the predictive probability.

The posterior is \(\mathrm{Beta}(3,3)\), with \(M=8-4=4\). At least \(5-2=3\) future responses are needed. The zero-response mass is $$ p_0=\frac{3\cdot4\cdot5\cdot6}{6\cdot7\cdot8\cdot9} =\frac{360}{3024}\approx0.1190. $$ Applying the recurrence gives \(p_1=2p_0\approx0.2381\), \(p_2=1.2p_1\approx0.2857\), \(p_3=(5/6)p_2\approx0.2381\), and \(p_4=0.5p_3\approx0.1190\). Thus, $$ \Pr(Y\geq3\mid x=2,n=4)=p_3+p_4 \approx0.2381+0.1190=0.3571. $$

The estimated chance of reaching 5 total responses is about 35.71%. Here the posterior is symmetric, so the predictive distribution for four remaining participants is symmetric around two responses: \(p_0=p_4\) and \(p_1=p_3\). That symmetry is a useful check on the calculation; it does not change which future counts meet the success rule.

Interpreting Results and Checking Calculations

A predictive probability answers a forward-looking question about the terminal count. It combines the uncertainty in the response rate after the interim data with the randomness of future binary outcomes. For a fixed \(N\) and \(r\), an interim result can therefore produce a probability near zero, near one, or somewhere between. The same observed response proportion can lead to different predictive probabilities when the remaining sample size or terminal target changes.

Several checks catch common calculation errors:

  • Check the remaining sample size. \(M=N-n\) must be nonnegative. If \(n>N\), the assumed interim state and planned total are inconsistent.
  • Check the posterior parameters. They are \(A=a+x\) and \(B=b+n-x\), not parameters formed by adding all \(n\) participants to the response component.
  • Check the success tail and its support. The first contributing future count is \(\max(0,r-x)\), but if \(r-x\leq0\) the probability is 1; if \(r-x>M\) it is 0. A sum must never include impossible future counts.
  • Check the mass calculation. The values \(p_0,\ldots,p_M\) should sum to 1, and the reported success probability must lie between 0 and 1.
  • Keep the target fixed. Changing \(r\) changes the tail, even if the interim data and posterior are unchanged.

A frequent mistake is to treat the posterior mean response rate as if it were known and calculate a binomial tail using that single value. That plug-in calculation omits posterior uncertainty in \(\theta\). The Beta-Binomial calculation instead averages the future binomial probability over the entire posterior distribution. Another mistake is to describe the predictive probability as the probability that the treatment is effective or that the null hypothesis is false. It is neither: its event is specifically that the final response count reaches the stated threshold.

The main alternative calculation is direct enumeration of the Beta-Binomial masses, using the beta-function formula for every \(y\) from 0 to \(M\). The recurrence is a convenient computational shortcut; direct evaluation is a useful independent check, especially when \(M\) is modest. A simulation can also approximate the probability by repeatedly drawing \(\theta\) from the posterior and then drawing \(Y\mid\theta\), but simulation adds Monte Carlo error and is unnecessary for small counts when exact summation is feasible.

These calculations rely on a fixed sample size and terminal rule, complete binary outcomes at the interim analysis, and the model assumptions stated above. A misspecified prior or a changing response probability can affect the result. The probability also depends on the chosen terminal target: it does not independently establish clinical importance, safety, or a justified stopping decision. Monitoring rules require a prespecified interpretation of the predictive probability, not an informal reaction to a single number.

Check Your Understanding

For each question, use a \(\mathrm{Beta}(1,1)\) prior unless otherwise stated. Solutions are included after the questions.

  1. A trial has observed 3 responses among 10 participants, plans a total of 12, and requires at least 5 responses for terminal success. What future count is required, and which predictive mass contributes to success?
  2. At an interim analysis, \(x=5\), \(n=12\), \(N=14\), and the terminal target is \(r=4\). What is the predictive probability of terminal success, without calculating any Beta-Binomial masses?
  3. At an interim analysis, \(x=1\), \(n=8\), \(N=10\), and \(r=5\). What is the predictive probability, and why?
  4. For \(x=4\), \(n=8\), \(N=10\), and \(r=5\), find the predictive probability of terminal success.

Solutions. (1) \(M=12-10=2\), and \(5-3=2\) additional responses are required; only \(p_2\) contributes. (2) The observed count already exceeds the target, since \(x=5\geq4\), so every possible future count meets the terminal rule and the probability is 1. (3) Only \(M=2\) participants remain, but \(5-1=4\) more responses would be needed; that is impossible, so the probability is 0. (4) The posterior is \(\mathrm{Beta}(5,5)\), \(M=2\), and one or more future responses are needed. Here \(p_0=(5\cdot6)/(10\cdot11)=30/110\), so the success probability is \(1-p_0=80/110\approx0.7273\), or 72.73%.

Clinical Biostats