Tutorials › Population Pharmacokinetics › Choosing Bootstrap Replicate Counts

Bootstrap and External Validation · Tutorial 409 of 599

Choosing Bootstrap Replicate Counts

Choose a bootstrap replicate count by matching Monte Carlo precision to the accuracy needed for standard-error and confidence-limit estimates.

Advanced 12 min read

What You'll Learn

  • Distinguish the number of attempted refits from the number of successful bootstrap replicates.
  • Approximate the Monte Carlo error in a bootstrap standard-error estimate.
  • Assess why confidence-limit precision depends on tail density as well as replicate count.
  • Set a replicate-count target from a stated precision requirement.
  • Use batch checks to assess endpoint stability without treating them as proof of convergence.
  • Recognize failure patterns and other limits of replicate-count calculations.

Why the Replicate Count Is a Precision Choice

A bootstrap analysis uses repeated resamples and model refits to approximate the sampling distribution of a statistic, such as clearance (\(CL\)) or an exposure measure. Those repeated calculations are themselves a Monte Carlo computation: a finite set of successful bootstrap replicates only approximates the distribution the bootstrap procedure defines. Too few replicates can make reported standard errors and confidence limits noticeably dependent on the particular random resamples generated.

The replicate count should therefore be chosen in relation to the quantity being reported and the precision needed for the analysis. Standard errors and confidence limits do not have identical Monte Carlo behavior. A standard-error estimate summarizes spread across the distribution; a confidence limit is a tail quantile and can be much more sensitive to the number of observations near that tail. There is no single replicate count that guarantees adequate precision for every parameter, model, and reporting purpose.

Definition: Let \(T_b^*\) be the value of a statistic from the \(b\)th successful bootstrap replicate, for \(b=1,\ldots,B\). The successful replicate count \(B\) is the number of valid replicate results used in the calculation. The Monte Carlo error is the variation in a bootstrap summary that would arise from generating a different finite set of bootstrap replicates, conditional on the observed data and the specified bootstrap procedure.

A failed refit does not contribute a valid \(T_b^*\), so the number of attempted refits may exceed \(B\). The earlier material on bootstrap convergence and failed replicates is relevant here: increasing the number of attempts can provide more successful replicates, but it does not make a systematic or informative failure mechanism harmless. Precision calculations below presume that the successful replicates are independent draws from the intended bootstrap distribution, or close enough for the approximations to be useful, and that the statistic is defined consistently across replicates.

Monte Carlo Error in a Bootstrap Standard Error

The bootstrap standard error is the standard deviation of the replicate statistics. Its estimate from \(B\) successful replicates is written \(\widehat{SE}_{boot}\). The question here is not how to interpret that standard error as sampling uncertainty; it is how much Monte Carlo variation to expect in its finite-\(B\) estimate.

A useful approximation follows from the sampling variability of a sample variance. Let the bootstrap distribution have standard deviation \(\sigma_*\) and standardized fourth moment \(\kappa=E[(T^*-\mu_*)^4]/\sigma_*^4\). For independent replicates, the large-\(B\) variance of the sample variance is approximately \(\sigma_*^4(\kappa-1)/B\). Applying the square-root transformation gives the following approximate relative Monte Carlo standard error for the estimated standard deviation:

$$ \frac{MCSE(\widehat{SE}_{boot})}{SE_{boot}} \approx \sqrt{\frac{\kappa-1}{4B}}. $$

If the replicate distribution is approximately normal, then \(\kappa\approx3\), giving the familiar planning approximation:

$$ \frac{MCSE(\widehat{SE}_{boot})}{SE_{boot}} \approx \frac{1}{\sqrt{2(B-1)}}. $$

The \(B-1\) version is a convenient finite-sample approximation; it is not an exact guarantee for a nonnormal bootstrap distribution. Rearranging gives a rough planning count for target relative Monte Carlo error \(r\):

$$ B \approx 1+\frac{1}{2r^2}. $$

This is a planning rule, not a universal minimum. It relies on independent replicate draws and a distribution whose fourth moment is not so large that the normal approximation is misleading. A heavy-tailed or irregular replicate distribution can require more replicates.

Worked Example: Planning for Standard-Error Precision

Suppose a hypothetical population-PK analysis estimates the bootstrap standard error of apparent clearance as \(0.20\ \mathrm{L/h}\). The analyst wants Monte Carlo error no greater than about 5% of that standard error. Assume, for planning, that the replicate distribution is approximately normal.

The relative-error target is \(r=0.05\). Using the normal approximation,

$$ B \approx 1+\frac{1}{2(0.05)^2} =1+\frac{1}{0.005} =201. $$

At \(B=200\), the relative Monte Carlo standard error is approximately \[ \frac{1}{\sqrt{2(199)}}=0.0501, \] or 5.01%. The corresponding absolute Monte Carlo standard error is approximately \[ 0.20\ \mathrm{L/h}\times0.0501=0.0100\ \mathrm{L/h}. \]

Thus about 201 successful replicates meet this rough planning target under the stated approximation. In practice, this is a modest target for a final analysis: the approximation does not cover tail limits, distribution irregularity, or failures, and a stricter precision goal or additional diagnostics may justify substantially more replicates.

Why Confidence Limits Often Need More Replicates

A confidence limit computed from bootstrap replicates is commonly an empirical quantile. For example, a two-sided percentile interval with nominal 95% coverage uses the 2.5th and 97.5th percentiles. The Monte Carlo precision of an empirical \(p\) quantile depends both on \(B\) and on how densely the bootstrap distribution is populated near the true quantile.

If the bootstrap distribution has a smooth density \(f\) that is positive at its \(p\) quantile \(q_p\), the large-sample approximation for the Monte Carlo standard error of the empirical quantile is:

$$ MCSE(\hat q_p) \approx \frac{\sqrt{p(1-p)/B}}{f(q_p)}. $$

The numerator describes uncertainty in the rank of the quantile; the denominator converts rank uncertainty into the statistic’s units. A small density at the endpoint means even a modest change in rank can move the endpoint substantially. For a \(p=0.025\) endpoint, the expected number of replicates below that endpoint is only \(0.025B\). Thus \(B=1{,}000\) provides about 25 replicates in that tail, while \(B=10{,}000\) provides about 250. A count that is adequate for a standard-error estimate may therefore be inadequate for stable tail limits.

The density \(f(q_p)\) is unknown and must itself be estimated if this formula is used to estimate endpoint Monte Carlo error. In practice, local density estimates can be unstable, especially with few tail observations, tied values, skewness, or a boundary. The formula is best treated as a guide to what controls endpoint precision, not as a precise promise about a particular dataset.

Worked Example: Estimating Monte Carlo Error for a Lower Limit

Consider a hypothetical bootstrap analysis of \(CL\), measured in \(\mathrm{L/h}\). Suppose \(B=2{,}500\) successful replicates, and a local density estimate near the 2.5th percentile is \(0.10\) per \(\mathrm{L/h}\). The estimated lower percentile limit is \(-0.40\ \mathrm{L/h}\). Use the quantile approximation to assess its Monte Carlo error.

For \(p=0.025\),

$$ MCSE(\hat q_{0.025}) \approx \frac{\sqrt{0.025(0.975)/2{,}500}}{0.10\ (\mathrm{L/h})^{-1}} = \frac{\sqrt{0.00000975}}{0.10\ (\mathrm{L/h})^{-1}} \approx 0.0312\ \mathrm{L/h}. $$

The approximate Monte Carlo standard error is therefore \(0.0312\ \mathrm{L/h}\), about 7.8% of the absolute endpoint value \(0.40\ \mathrm{L/h}\). This is not a confidence interval for the true parameter. It describes the approximate simulation variability of this estimated bootstrap quantile, conditional on the data and procedure. The density estimate is a key assumption: if the actual tail density is lower than \(0.10\) per \(\mathrm{L/h}\), endpoint Monte Carlo error will be larger.

Practical Precision Checks

A useful workflow starts by specifying precision in the units and context of the reported quantity. For a standard error, a relative target may be sensible; for a confidence limit, an absolute tolerance in units such as \(\mathrm{L/h}\) or \(\mathrm{mg\cdot h/L}\) is often easier to interpret. The target should be consequentially small compared with the precision at which the result will be reported, not merely small in a mathematical sense.

1
Set the target before running the final bootstrap.
State the desired relative Monte Carlo error for standard errors and, where important, an absolute tolerance for each reported confidence limit. Different parameters or endpoints can require different targets.
2
Choose an initial successful count.
Use the standard-deviation approximation as a first planning calculation. For tail quantiles, also consider how many replicates will fall beyond the target percentile and whether local endpoint density is likely to be low.
3
Run in batches and inspect the summaries.
Track the successful count, the standard errors, and the confidence limits as additional valid replicates accumulate. Compare changes with the pre-specified tolerances; do not rely on one unchanged decimal place alone.
4
Review failures and distribution shape.
Record attempts as well as successful replicates. Investigate whether failures cluster by parameter region or resample type, and inspect the replicate distribution for skewness, heavy tails, ties, boundaries, or multiple modes.

Batch checks are diagnostics, not proof that a limit has converged. Cumulative estimates at successive counts are dependent because earlier replicates remain in the later calculation. Small changes can occur by chance, and a later batch can move a previously stable endpoint. Where feasible, compare independent batches or continue adding batches until estimates remain within the stated tolerance across more than one update. For independent estimates with Monte Carlo standard errors \(m_1\) and \(m_2\), the standard error of their difference is approximately \(\sqrt{m_1^2+m_2^2}\); this can help distinguish a meaningful batch discrepancy from ordinary simulation variation.

Worked Example: Checking Endpoint Precision in Batches

A hypothetical analysis reports the lower 2.5th percentile limit for a model-derived exposure, measured in \(\mathrm{mg\cdot h/L}\). The team sets an absolute Monte Carlo tolerance of \(0.02\ \mathrm{mg\cdot h/L}\). A local density estimate near the endpoint is \(0.20\) per \(\mathrm{mg\cdot h/L}\), and the endpoint estimates from cumulative runs are:

Successful replicates \(B\)Estimated lower limit (\(\mathrm{mg\cdot h/L}\))
1,0005.42
2,0005.39
4,0005.37
8,0005.36

At \(B=8{,}000\), the quantile approximation gives

$$ MCSE(\hat q_{0.025}) \approx \frac{\sqrt{0.025(0.975)/8{,}000}}{0.20\ (\mathrm{mg\cdot h/L})^{-1}} = \frac{0.001745}{0.20\ (\mathrm{mg\cdot h/L})^{-1}} \approx 0.00873\ \mathrm{mg\cdot h/L}. $$

Under the assumed density estimate, this is below the stated \(0.02\ \mathrm{mg\cdot h/L}\) tolerance. The change from 4,000 to 8,000 replicates is \(0.01\ \mathrm{mg\cdot h/L}\), also below the tolerance. These checks support the chosen count for this endpoint, but do not establish that the bootstrap distribution is appropriate or that the density estimate is accurate. The count should be reconsidered if the local tail is sparse, the estimate changes substantially in a later batch, or failures suggest that successful refits are not representative.

Diagnostics, Alternatives, and Limitations

Several warning signs indicate that a simple replicate-count calculation may be unreliable:

  • Few tail replicates. With \(B=1{,}000\), a 2.5th percentile is determined by observations near the 25th ordered replicate. A handful of unusual values or a small change in rank can shift the limit.
  • Unstable endpoint estimates. Large changes across successive batches, particularly relative to the chosen tolerance, call for more replicates and an examination of the replicate distribution.
  • High skewness or heavy tails. The normal-based standard-error approximation assumes a well-behaved fourth moment. Extreme replicate values can increase variability and make a small-\(B\) approximation optimistic.
  • Boundaries, ties, or multimodality. A smooth positive density at the quantile may not be a reasonable approximation. Empirical quantiles can jump between distinct values or modes.
  • Selective failures. If valid refits are disproportionately obtained from particular resamples or parameter regions, adding more successful replicates does not by itself repair the resulting selection problem.

One alternative is to use an analytic or model-based approximation to uncertainty instead of relying on a large bootstrap computation. Such an approach may be faster, but it answers the intended question only if its assumptions and model approximation are appropriate. Another is to run independent bootstrap batches and compare their summaries; this is a useful Monte Carlo diagnostic but does not remove bias or misspecification in the bootstrap procedure. Increasing \(B\) reduces finite-simulation noise at the usual approximate rate of \(1/\sqrt{B}\), but does not make the underlying resampling design, refit strategy, or model valid.

A replicate count is consequently a computational precision choice, not a substitute for study design or model assessment. Precision targets should be reported or documented alongside the achieved successful count, attempted count, failure pattern, and any endpoint checks. A visually smooth histogram alone is not evidence that tail quantiles are precise, and printing more decimal places does not improve their Monte Carlo accuracy.

Key takeaway: Plan standard-error precision using its approximate Monte Carlo error, and assess confidence-limit precision separately because it depends strongly on the tail density. Use a stated tolerance, count successful refits, and treat batch stability as a diagnostic rather than a guarantee.

Check Your Understanding

Answer the questions, then compare your reasoning with the solutions.

  1. Under the approximately normal replicate-distribution rule, what relative Monte Carlo error is expected for a bootstrap standard error with \(B=500\) successful replicates?
  2. Why can the 2.5th percentile require more replicates than a bootstrap standard error?
  3. Suppose 1,200 refits were attempted and 1,000 produced valid results. Which count belongs in the usual Monte Carlo precision formulas, and what else should be reported?
  4. What does a Monte Carlo standard error of \(0.03\ \mathrm{L/h}\) for a lower confidence limit describe?

Solutions. (1) The approximation is \(1/\sqrt{2(499)}=0.0317\), or about 3.17% relative error. (2) A tail quantile is estimated from relatively few observations near the tail, and its value depends on the local density: low density makes rank variation translate into larger changes in the endpoint. (3) Use \(B=1{,}000\) successful replicates; also report the 1,200 attempts and investigate the 200 failed refits, since failures could be selective. (4) It estimates the simulation variability of the reported bootstrap endpoint across repeated finite bootstrap runs, conditional on the observed data and specified procedure; it is not a measure of uncertainty in the true parameter.

Clinical Biostats