Tutorials › Response-Adaptive Randomization › Neyman Allocation Under Unequal Per-Patient Costs

Optimal Allocation Targets · Tutorial 109 of 501

Neyman Allocation Under Unequal Per-Patient Costs

Learn how to derive and interpret cost-adjusted two-arm Neyman targets, verify them under a fixed budget, and recognize when the assumptions behind the targets do not fit a study.

Intermediate 10 min read

What You'll Learn

  • State the assumptions for cost-adjusted two-arm Neyman allocation.
  • Derive the optimal sample-size ratio from variance minimization under a budget constraint.
  • Calculate continuous allocation targets and check their total cost.
  • Compare the cost-adjusted targets with equal allocation under the same budget.
  • Identify model and implementation conditions that can make the targets inappropriate.
  • Diagnose and correct a reversed cost adjustment.

Why Patient Costs Change the Allocation

When the two treatment arms have different outcome variances, assigning more patients to the more variable arm can reduce the variance of the estimated difference in mean outcomes. But the number of patients is not the only resource that matters: if a patient in one arm costs more to recruit or treat, allocating the same number to each arm may use the budget inefficiently. Cost-adjusted Neyman allocation balances these two considerations for a two-arm comparison with a fixed total budget.

The result is an allocation target: it specifies how many patients would go to each arm in an idealized continuous optimization. It is not, by itself, a rule for assigning each arriving patient in a response-adaptive trial. The derivation concerns the target under specified costs and outcome variances.

Definition: Let arm \(1\) and arm \(0\) have independent outcome variances \(\sigma_1^2\) and \(\sigma_0^2\), sample sizes \(n_1\) and \(n_0\), and per-patient costs \(c_1\) and \(c_0\). For estimating the difference in arm means, cost-adjusted two-arm Neyman allocation is the allocation minimizing \(\sigma_1^2/n_1+\sigma_0^2/n_0\), subject to \(c_1n_1+c_0n_0=B\), where \(B\) is the available variable-cost budget.

The target concerns precision for the difference in means, not patient benefit or expected treatment success. For the variance expression to apply, outcomes within each arm are assumed to be independent observations with the stated arm-specific variance, the two arm samples are independent, and the estimator is the difference between the two sample means. The costs are assumed positive, known, and constant per patient within each arm. The total budget is assumed to consist of these per-patient costs, with no fixed or other overhead costs.

The variances are treated as known design inputs, and both arms are assumed to have positive variance. These conditions make the continuous optimization well-defined. If variances or costs are uncertain, costs vary among patients, or the study’s estimand and analysis produce a different variance expression, the target derived here may not be appropriate without modification.

Deriving the Cost-Adjusted Ratio

For independent arm samples, the variance of the estimated difference \(\bar{x}_1-\bar{x}_0\) is \(\sigma_1^2/n_1+\sigma_0^2/n_0\). Under the fixed-budget constraint, reducing that variance requires choosing both sample sizes: an additional patient improves precision in their arm but uses part of the budget.

A direct constrained minimization gives the allocation ratio. Introduce a multiplier \(\lambda\) for the budget constraint and minimize \(\sigma_1^2/n_1+\sigma_0^2/n_0+\lambda(c_1n_1+c_0n_0-B)\). At an interior optimum, the partial derivatives with respect to both sample sizes are zero:

$$ -\frac{\sigma_1^2}{n_1^2}+\lambda c_1=0, \qquad -\frac{\sigma_0^2}{n_0^2}+\lambda c_0=0. $$

Because sample sizes, variances, and costs are positive, these equations imply \(n_1=\sigma_1/\sqrt{\lambda c_1}\) and \(n_0=\sigma_0/\sqrt{\lambda c_0}\). Dividing one expression by the other gives the cost-adjusted Neyman ratio:

$$ \frac{n_1}{n_0} = \frac{\sigma_1}{\sigma_0} \sqrt{\frac{c_0}{c_1}}. $$

Thus the more variable arm receives more patients, while the more expensive arm receives fewer, all else equal. The cost adjustment is a square root of the inverse cost ratio, not the inverse cost ratio itself. The sample-size ratio alone does not give the target counts; the budget determines their scale.

To obtain the counts, the derivative equations show that each \(n_i\) is proportional to \(\sigma_i/\sqrt{c_i}\). Substituting \(n_i=k\sigma_i/\sqrt{c_i}\) into the budget constraint gives \(k\sum_i\sigma_i\sqrt{c_i}=B\). Therefore the two continuous targets are:

$$ n_1 = \frac{B(\sigma_1/\sqrt{c_1})} {\sigma_1\sqrt{c_1}+\sigma_0\sqrt{c_0}}, \qquad n_0 = \frac{B(\sigma_0/\sqrt{c_0})} {\sigma_1\sqrt{c_1}+\sigma_0\sqrt{c_0}}. $$

The stationary point is the global minimum under the stated assumptions. Each term \(\sigma_i^2/n_i\) is strictly convex for \(n_i>0\), so their sum is strictly convex; the positive-sample-size budget constraint is linear. Also, as either sample size approaches zero, its variance term diverges. Consequently the feasible interior stationary point is the unique minimum.

Substituting these targets back into the variance expression gives the minimum continuous-target variance:

$$ \operatorname{Var}(\bar{x}_1-\bar{x}_0) = \frac{(\sigma_1\sqrt{c_1}+\sigma_0\sqrt{c_0})^2}{B}. $$

This formula is useful as a check, but it depends on the same assumptions as the allocation itself. In particular, it does not account for integer sample sizes, fixed costs, or uncertainty in the variance inputs.

Worked Example: Equal Targets Despite Different Costs and Variances

Suppose a hypothetical trial has \(\sigma_1=12\) outcome units and \(\sigma_0=8\) outcome units. Each patient in arm 1 costs 9 budget units and each patient in arm 0 costs 4 budget units. The variable-cost budget is 2,600 units. Assume independent observations in the two arms and use the arm variances as the planning inputs.

The allocation ratio is \(\frac{n_1}{n_0}=\frac{12}{8}\sqrt{\frac{4}{9}}=1.5(2/3)=1\). The larger standard deviation in arm 1 is exactly offset by its higher per-patient cost, so the target sample sizes are equal.

The budget constraint is \(9n_1+4n_0=2{,}600\). With \(n_1=n_0=n\), this becomes \(13n=2{,}600\), so \(n=200\) patients per arm. The cost check is \(9(200)+4(200)=1{,}800+800=2{,}600\) budget units.

The variance of the estimated mean difference at these targets is \(\frac{12^2}{200}+\frac{8^2}{200}=\frac{144}{200}+\frac{64}{200}=0.72+0.32=1.04\) squared outcome units. The standard error is \(\sqrt{1.04}\approx1.020\) outcome units. The equality of sample sizes does not mean the arms have equal costs or equal variances; it is the result of their combined effects.

Budget Checks and Comparisons

A useful way to check a proposed allocation is to verify both the ratio and the cost constraint. The ratio checks whether the target balances variance and cost; the budget check confirms that the targets use the stated resource total. A variance calculation provides an additional check on precision. The following example illustrates all three.

Worked Example: Unequal Costs, Unequal Targets

Consider a hypothetical comparison with \(\sigma_1=10\) and \(\sigma_0=6\) outcome units, \(c_1=16\) and \(c_0=4\) budget units per patient, and total variable-cost budget \(B=4{,}000\) budget units. Assume the independent-arm mean-comparison model and fixed costs per patient described above.

The ratio is \(\frac{n_1}{n_0}=\frac{10}{6}\sqrt{\frac{4}{16}}=\frac{5}{3}\frac{1}{2}=\frac{5}{6}\). Although arm 1 is more variable, it is also four times as costly per patient, so its optimal sample size is smaller than arm 0’s.

The denominator in the target formulas is \(10\sqrt{16}+6\sqrt{4}=40+12=52\). Therefore \(n_1=\frac{4{,}000(10/4)}{52}=\frac{10{,}000}{52}=\frac{2{,}500}{13}\approx192.3077\) and \(n_0=\frac{4{,}000(6/2)}{52}=\frac{12{,}000}{52}=\frac{3{,}000}{13}\approx230.7692\).

Using the exact targets, the total cost is \(16(2{,}500/13)+4(3{,}000/13)=(40{,}000+12{,}000)/13=4{,}000\) budget units. The continuous-target variance is \(100/(2{,}500/13)+36/(3{,}000/13)=0.52+0.156=0.676\) squared outcome units.

For comparison, equal sample sizes under this budget would require \(20n=4{,}000\), or \(n=200\) in each arm. The variance would then be \(100/200+36/200=0.68\) squared outcome units. In this example cost-adjusted allocation gives a slightly smaller variance, \(0.676\) rather than \(0.680\) squared outcome units, at the same variable-cost budget. The difference is modest; the optimality statement does not imply a large practical gain in every setting.

Worked Example: Verifying Exact Targets Before Rounding

Suppose a hypothetical study has equal standard deviations of 8 outcome units in both arms, costs of 2 budget units per arm 1 patient and 8 per arm 0 patient, and a total variable-cost budget of 2,000 budget units. The model assumptions are independent arm samples, known planning variances, positive costs, and no budgeted overhead.

The ratio is \(\frac{n_1}{n_0}=\frac{8}{8}\sqrt{\frac{8}{2}}=2\). From the budget constraint and \(n_1=2n_0\), \(2(2n_0)+8n_0=2{,}000\), so \(12n_0=2{,}000\). Thus the exact continuous targets are \(n_0=500/3\) and \(n_1=1{,}000/3\).

Using the exact targets, the cost is \(2(1{,}000/3)+8(500/3)=(2{,}000+4{,}000)/3=2{,}000\) budget units. Their variance is \(64/(1{,}000/3)+64/(500/3)=192/1{,}000+192/500=0.1920+0.3840=0.5760\) squared outcome units.

Equal sample sizes under the same budget would require \(2n+8n=2{,}000\), giving \(n=200\) per arm. That allocation has variance \(64/200+64/200=0.6400\) squared outcome units. The cost-adjusted continuous targets therefore reduce the variance under these inputs. In practice sample sizes must be integers, so rounding these targets requires a separate feasibility check against the budget; the exact continuous targets should not be described as integer counts.

When the Target Is Useful—and When It Can Mislead

Cost-adjusted Neyman allocation provides a transparent precision target when the study’s aim is to estimate a two-arm mean difference under a fixed variable-cost budget. It also makes the direction of the trade-off explicit: larger standard deviation favors a larger sample, while larger per-patient cost works against it. The target can differ substantially from equal allocation when costs or variances differ substantially, but its advantage should be evaluated using the actual planning inputs and the intended estimator.

It is important not to confuse a fixed budget with a fixed total sample size. With a fixed total sample size, the constraint is \(n_1+n_0=N\), not \(c_1n_1+c_0n_0=B\). The corresponding allocation problem is different. Likewise, a design chosen to balance costs, expected patient outcomes, or a different statistical estimand need not minimize the variance used here.

Design featureImplication for the target
Unequal outcome standard deviationsFavors more patients in the arm with larger standard deviation.
Unequal per-patient costsFavors fewer patients in the arm with larger cost, other inputs equal.
Fixed total sample size rather than fixed budgetRequires a different constraint and generally a different allocation.
Fixed overhead or variable within-arm costsMay invalidate the simple linear budget constraint used in this derivation.
Integer sample sizes or minimum arm sizesMay require feasible adjustments to the continuous targets.

Diagnostics begin with the inputs and constraints. Confirm that costs are expressed in the same units, that \(B\) is the budget available for the per-patient costs being modeled, and that \(\sigma_1,\sigma_0\) are standard deviations on the outcome scale used for the mean comparison. Then check that each target is positive, that their ratio matches the cost-adjusted formula, and that \(c_1n_1+c_0n_0=B\). A failure of any of these checks points to an algebra, unit, or model-specification problem.

A frequent mistake is to reverse the cost ratio and write \(n_1/n_0=(\sigma_1/\sigma_0)\sqrt{c_1/c_0}\). That would allocate relatively more patients to an arm merely because it costs more, contrary to the fixed-budget precision trade-off. For a quick direction check, hold the standard deviations equal: if arm 1 becomes more expensive, its optimal sample size should decrease relative to arm 0. The correct factor is \(\sqrt{c_0/c_1}\).

The calculation also has limitations. The continuous solution may not correspond to feasible integer counts, and a very small target could conflict with a protocol’s minimum arm size. In addition, misspecified variance inputs can shift the target, while omitted overhead can make the stated budget check misleading. These issues do not alter the derivation; they indicate that its assumptions or constraints do not fully describe the intended design. The allocation is an optimum only for the specified variance objective, budget, and inputs.

Key takeaway: With positive arm variances and per-patient costs, the fixed-budget precision target satisfies \(\frac{n_1}{n_0}=\frac{\sigma_1}{\sigma_0}\sqrt{\frac{c_0}{c_1}}\). More variability increases an arm’s target share; greater cost decreases it. Always verify the target against the budget and the assumptions behind the variance expression.

Check Your Understanding

Answer each question, then compare your work with the solutions.

  1. If \(\sigma_1=5\), \(\sigma_0=10\), \(c_1=25\), and \(c_0=4\), what is the cost-adjusted ratio \(n_1/n_0\)?
  2. For \(\sigma_1=6\), \(\sigma_0=9\), \(c_1=9\), \(c_0=1\), and \(B=1{,}800\), calculate the exact continuous targets and their variance.
  3. With equal standard deviations, what happens to \(n_1/n_0\) if \(c_1\) increases while \(c_0\) stays fixed?
  4. A proposed calculation uses \(n_1/n_0=(\sigma_1/\sigma_0)\sqrt{c_1/c_0}\). Explain the error.
  5. Name two conditions under which the fixed-budget derivation may not give the appropriate design target.

Solutions. (1) The ratio is \((5/10)\sqrt{4/25}=0.5(0.4)=0.2\), so \(n_1/n_0=1/5\). (2) The denominator is \(6\sqrt{9}+9\sqrt{1}=27\). Thus \(n_1=1{,}800(6/3)/27=400/3\approx133.3333\) and \(n_0=1{,}800(9/1)/27=600\). The cost is \(9(400/3)+1(600)=1{,}200+600=1{,}800\) budget units. The variance is \(36/(400/3)+81/600=0.270+0.135=0.405\) squared outcome units. (3) The ratio decreases because the correct formula includes \(\sqrt{c_0/c_1}\). (4) The cost ratio has been reversed: that expression incorrectly favors the more costly arm. (5) Examples include a fixed total sample size instead of a fixed budget, unmodeled overhead costs, within-arm costs that are not constant per patient, or a variance expression that does not apply to the intended estimator.

Clinical Biostats