Tutorials › Adaptive Clinical Trial Design › Documenting A Prespecified Re-Estimation Algorithm

Sample Size Re-Estimation · Tutorial 357 of 799

Documenting A Prespecified Re-Estimation Algorithm

Learn how to turn a sample-size re-estimation plan into a deterministic, auditable algorithm with explicit inputs, calculations, bounds and missing-data rules.

Advanced 12 min read

What You'll Learn

  • Specify when an interim re-estimation occurs and which records enter the analysis.
  • Define the variance estimator and sample-size calculation before examining interim data.
  • Apply prespecified minimum and maximum sample-size limits in a reproducible order.
  • Distinguish an available estimate from a fallback action when data are insufficient.
  • Record decisions and deviations without changing the primary treatment question.
  • Recognize how incomplete documentation can make an adaptation unauditable.

From a Design Intention to an Executable Rule

A plan to “re-estimate the sample size using the interim variance” is not yet an algorithm. It leaves unresolved which participants count as available, when the data are frozen, how the variance is calculated, how the estimate becomes a sample size, and what happens if the estimate cannot be calculated. Different answers can produce different trial sizes from the same trial data.

A prespecified re-estimation algorithm closes those gaps before interim results are examined. It should make the mapping from permitted data to action sufficiently explicit that an independent reviewer can reproduce the decision. The rule concerns the planned sample size; it does not authorize changing the primary endpoint, treatment contrast, or analysis question.

Definition: A prespecified re-estimation algorithm is a written, deterministic rule that specifies the interim timing, eligible data, calculations, decision thresholds, sample-size bounds, and actions for unavailable or unusable data. Given the same permitted inputs, two qualified analysts following the rule should reach the same sample-size decision.

The specification should be written before the interim data are accessed by anyone responsible for the adaptation. It should also identify who can access the data and who makes, verifies, and records the decision. These controls do not replace the statistical rule; they help ensure the rule is followed as written.

State the Model and Calculation

The worked specifications below use a hypothetical two-arm trial with equal allocation and a continuous endpoint. The planned comparison is a two-sided test of a fixed mean difference \(\delta=5\) points at \(\alpha=0.05\), with target power \(90\%\). Assume independent participant outcomes, normally distributed within each arm with a common variance \(\sigma^2\), and a normal-approximation sample-size calculation. These assumptions motivate the calculation; they are not guaranteed by writing them into a protocol.

For \(n\) evaluable participants per arm, the variance of the difference in sample means is \(2\sigma^2/n\). The approximate sample size that achieves the specified power is therefore:

$$ n_{\mathrm{eval}} = \left\lceil \frac{2\sigma^2(z_{1-\alpha/2}+z_{1-\beta})^2}{\delta^2} \right\rceil, \qquad \beta=1-0.90=0.10. $$

Here, \(n_{\mathrm{eval}}\) is the required number of evaluable participants per arm; \(z_q\) is the \(q\)-quantile of the standard normal distribution; and the ceiling function rounds upward to the next integer. With \(\alpha=0.05\), \(z_{0.975}=1.960\); with 90% power, \(z_{0.90}=1.282\). Thus the squared quantile sum is approximately \(10.51\). If the anticipated proportion with an evaluable endpoint is \(q=0.90\), the corresponding randomized target per arm before applying bounds is \(\lceil n_{\mathrm{eval}}/q\rceil\).

The variance estimate used at interim must also be defined exactly. For \(n_A\) and \(n_B\) evaluable participants in arms A and B, let \(s_A^2\) and \(s_B^2\) be their usual sample variances. Under the common-variance model, the pooled within-arm estimate is:

$$ s_p^2 = \frac{(n_A-1)s_A^2+(n_B-1)s_B^2} {n_A+n_B-2}. $$

This calculation uses within-arm variation, not the difference between the arm means. A protocol must still specify the variance estimator, data cutoff, and eligibility rules: “use the pooled variance” alone is not sufficiently detailed.

Justification: Under the stated normal, independent, common-variance model, each arm mean has variance \(\sigma^2/n\). Independence between arms gives variance \(2\sigma^2/n\) for the estimated difference. Standardizing a true difference \(\delta\) gives a noncentrality of \(\delta\sqrt{n/(2\sigma^2)}\). Requiring this to exceed \(z_{1-\alpha/2}+z_{1-\beta}\) yields the displayed sample-size expression before rounding. The formula is an approximation based on those assumptions, not a guarantee of achieved power under every data-generating process.

Worked Example: Specify and Apply the Main Rule

Worked Example: A Complete-Data Variance Update

Suppose a hypothetical protocol requires an interim review after 40 participants per arm have been randomized and their 28-day endpoint windows have closed. The data cutoff is a specified date and time. Only endpoint values that are recorded, verified, and available at that cutoff enter the variance calculation. No imputation is used for this interim calculation. Re-estimation proceeds only if at least 30 evaluable outcomes are available in each arm; otherwise the fallback rule described below applies.

The protocol specifies \(s_p^2\) as the estimator, the fixed \(\delta=5\), two-sided \(\alpha=0.05\), 90% power, and \(q=0.90\). The hypothetical interim summary is \(n_A=n_B=40\), \(s_A^2=144\) points squared, and \(s_B^2=196\) points squared. Both arms exceed the 30-outcome threshold, so the variance estimate is available:

$$ s_p^2 = \frac{(40-1)(144)+(40-1)(196)}{40+40-2} = \frac{5616+7644}{78} = 170.0\ \text{points}^2. $$

Substitute this estimate into the sample-size formula:

$$ n_{\mathrm{eval}} = \left\lceil \frac{2(170.0)(1.960+1.282)^2}{5^2} \right\rceil = \left\lceil \frac{340(10.51)}{25} \right\rceil = \lceil 142.9\rceil = 143\ \text{evaluable participants per arm}. $$

Allowing for the prespecified 10% without an evaluable endpoint gives \(\lceil143/0.90\rceil=\lceil158.9\rceil=159\) randomized participants per arm before bounds. If the protocol sets a final target between 100 and 200 randomized participants per arm, this value is within bounds. The rule therefore sets the target at 159 per arm. With 40 already randomized per arm, the trial plans to randomize 119 additional participants per arm, assuming no operational constraint or protocol-defined correction to the count.

The result is a sample-size decision under the specified calculation and assumptions. It is not evidence that the true variance equals 170.0 points squared, nor does the arithmetic alone establish that the adaptive design meets its error-rate or power objectives.

Make Thresholds, Bounds, and Fallbacks Unambiguous

An auditable rule states both the threshold and the action on either side of it. For example, “at least 30 evaluable outcomes in each arm” means that 30 qualifies and 29 does not. It should also state what happens if the variance estimate is non-finite, a required field is missing, or the data query remains unresolved at the cutoff. Do not leave those cases to a discretionary judgment made after seeing the interim data.

For a concrete rule, suppose the protocol uses the planning standard deviation \(\sigma_0=15\) points as the fallback if either arm has fewer than 30 evaluable outcomes, or if the prespecified variance calculation cannot be completed. It then applies the same sample-size formula, attrition adjustment, and bounds. This fallback is a design choice, not a universal recommendation; its adequacy should be assessed for the particular trial.

The order of operations also matters. One precise sequence is: calculate the unrounded evaluable target; round it upward; divide by \(q\) and round upward to obtain the randomized target; apply the minimum and maximum to that randomized target; then subtract participants already randomized per arm to determine additional enrollment. If current enrollment already exceeds the bounded target, the protocol must say whether to stop enrollment at the next feasible point rather than attempt to remove participants.

Worked Example: Insufficient Interim Outcomes

At the specified cutoff, suppose the hypothetical trial has 40 randomized participants per arm, but only 27 evaluable endpoint outcomes in arm B. The threshold is not met, even if arm A has 35 evaluable outcomes. The protocol therefore uses the fixed fallback \(\sigma_0=15\) points; it does not substitute an informal estimate from arm A alone.

The fallback calculation is:

$$ n_{\mathrm{eval}} = \left\lceil \frac{2(15^2)(1.960+1.282)^2}{5^2} \right\rceil = \left\lceil \frac{450(10.51)}{25} \right\rceil = \lceil 189.2\rceil = 190\ \text{evaluable participants per arm}. $$

The randomized target before bounds is \(\lceil190/0.90\rceil=\lceil211.1\rceil=212\) per arm. If the maximum is 200 randomized participants per arm, the final target is 200, not 212. With 40 already randomized per arm, the rule calls for 160 additional participants per arm. Because the cap is below the calculated target, the protocol should report that the bound constrained the target; it should not claim that the uncapped calculation was achieved.

Worked Example: Applying the Minimum Bound

Suppose a complete-data interim estimate is \(s_p^2=64\) points squared. The threshold is met, and all other inputs remain as specified. Then:

$$ n_{\mathrm{eval}} = \left\lceil \frac{2(64)(10.51)}{25} \right\rceil = \lceil 53.81\rceil = 54, \qquad \left\lceil\frac{54}{0.90}\right\rceil = 60\ \text{randomized participants per arm}. $$

If the minimum final target is 100 randomized participants per arm, the bounded target is 100, not 60. With 40 already randomized per arm, the planned additional enrollment is 60 per arm. The minimum is a prespecified constraint; it does not change the formula or mean that the estimate itself called for 100 participants.

What the Written Specification Must Let a Reviewer Reproduce

A useful specification is operational, not merely statistical. It should let a reviewer reconstruct the decision from a dated data extract, the locked analysis code or calculation record, and the protocol’s stated constants. At minimum, record:

  • Timing: the trigger for review, outcome window, data cutoff, and any rule for a delayed review.
  • Inputs: endpoint definition, evaluability rules, analysis population, arm counts, and the source and units of each data field.
  • Calculation: the variance estimator, target contrast, type I error level, power, quantiles or method, attrition assumption, and rounding order.
  • Decision rules: the exact threshold for using interim data, fallback action, lower and upper bounds, and treatment of a target below current enrollment.
  • Governance and record: who receives which data, who verifies the calculation, the final decision, date, code or worksheet version, and any deviation and its resolution.

These details also support diagnostics. Check that arm counts match the cutoff, variances are in squared endpoint units, the denominator of the pooled variance is correct, and the computed target follows the documented rounding and bounding order. Compare the entered values with the source extract and have a second qualified person independently reproduce the decision. Investigate unexpected values or inconsistencies using prespecified procedures; do not silently remove observations, change the estimator, or choose a more convenient fallback.

A fixed sample-size design avoids interim re-estimation and its operational data-access requirements, but cannot respond to an unanticipated nuisance variance in the same way. A re-estimation design can use a prespecified nuisance-parameter update, but requires a clear rule and evaluation of its statistical behavior. Blinded and unblinded inputs are not interchangeable by default: the chosen data access and estimator must be specified and justified. A written algorithm by itself does not establish that the adaptive design controls type I error or attains its intended power; those properties require design-specific assessment, including simulation when appropriate.

Common Documentation Failures

  • “Re-estimate as needed.” This permits discretion after the data are seen. Replace it with a trigger, calculation, thresholds, and actions for every specified case.
  • Unclear data availability. “Use interim data” does not define how late, missing, or unverified outcomes are handled. State the cutoff, evaluability rules, minimum counts, and fallback.
  • Bounds without an order. Rounding, attrition adjustment, and truncation can yield different targets if applied in different orders. Write the sequence explicitly.
  • Confusing a cap with a successful target. A maximum can constrain the calculated sample size. Report the capped decision as such rather than implying the uncapped target was reached.
  • Changing the question while updating the size. A variance-based update does not authorize changing the endpoint or target contrast. Keep the primary question fixed and document any permitted adaptation separately.
Key takeaway: An auditable re-estimation rule defines the data, timing, calculation, thresholds, bounds, fallback, and decision record in advance. It should produce one reproducible action for every prespecified situation, including insufficient or unusable interim data.

Check Your Understanding

Answer each question using the stated hypothetical design: two-sided \(\alpha=0.05\), 90% power, \(\delta=5\) points, \(q=0.90\), and sample-size formula given above.

  1. If the interim threshold is at least 30 evaluable outcomes in each arm, does an estimate based on 30 outcomes in one arm and 29 in the other qualify?
  2. For \(s_p^2=100\) points squared, calculate the evaluable target and the randomized target before bounds.
  3. If that randomized target is 145 per arm, the maximum is 140 per arm, and 40 participants per arm are already randomized, what does the rule require?
  4. Why should a protocol specify whether rounding occurs before or after applying the attrition adjustment?
  5. Does documenting a deterministic variance-based sample-size rule alone prove that the adaptive design controls type I error? Explain.

Solutions. (1) No. The rule requires at least 30 in each arm; 29 in one arm triggers the specified fallback. (2) \(n_{\mathrm{eval}}=\lceil2(100)(10.51)/25\rceil=\lceil84.08\rceil=85\) per arm. The randomized target before bounds is \(\lceil85/0.90\rceil=\lceil94.44\rceil=95\) per arm. (3) The maximum sets the final target at 140 per arm, so 100 additional participants per arm are planned. The cap constrains the calculated target. (4) Because rounding and division by \(q\) need not give the same integer target in different orders; fixing the order makes the decision reproducible. (5) No. The rule makes the adaptation reproducible, but error-rate behavior depends on the design and must be assessed separately.

Clinical Biostats