Why the Simulation Target Must Be Explicit
A simulation result depends not only on the model and scenario but also on what is allowed to vary. A prediction calculated at one fitted parameter vector answers a different question from a prediction averaged over uncertainty in that vector. Both can be appropriate. The important requirement is to specify which question the simulation is designed to answer before interpreting its output.
The earlier material on simulation targets and scenario definitions establishes the need to hold the scenario clear. Here, assume a scenario \(s\) has been specified, including its dose, time points, and any fixed covariate values. Let \(\theta\) denote the model parameter vector, and let \(Y\) denote a simulated outcome under that scenario. The distinction in this tutorial concerns whether \(\theta\) is fixed at its fitted value or varied over a stated parameter-uncertainty distribution.
The term uncertainty-integrated is useful because “unconditional” can otherwise be misunderstood. It does not mean that every input is random or that the simulation represents every source of variability. It identifies one particular operation: averaging across parameter values under \(q(\theta)\). For frequentist analyses, such a distribution can represent uncertainty in an estimator; in a Bayesian analysis, it can represent a posterior distribution. The interpretation depends on how \(q(\theta)\) was defined.
Writing the Two Targets
Let \(m(s,\theta)=E(Y\mid s,\theta)\) be the model-implied mean outcome for scenario \(s\) at parameter vector \(\theta\). A conditional prediction of the mean is \(m(s,\hat{\theta})\). The uncertainty-integrated mean is the average of this model-implied mean across parameter values:
If \(Y\) has additional stochastic variation conditional on \(\theta\), write its conditional distribution as \(p(y\mid s,\theta)\). The conditional outcome distribution is \(p(y\mid s,\hat{\theta})\); the integrated outcome distribution averages those conditional distributions:
This distinction applies to event probabilities as well. If \(A\) is an event such as concentration exceeding a threshold, the conditional probability is \(P(A\mid s,\hat{\theta})\). The integrated probability is the average conditional event probability under \(q(\theta)\). In general, these targets differ, especially when the model prediction or event probability changes nonlinearly with \(\theta\).
A Short Justification: Integrated Means and Variances
For the integrated target, averaging conditional means gives the overall mean. This follows by taking the expectation first conditional on \(\theta\), then over \(q(\theta)\):
The same separation clarifies what variation is included in an integrated outcome distribution. Let \(v(s,\theta)=\operatorname{Var}(Y\mid s,\theta)\), and let \(\mu_{\mathrm{int}}=E(Y\mid s)\). Add and subtract the conditional mean \(m(s,\theta)\) inside the squared deviation:
The first term is the average conditional outcome variance; the second is the variance of the conditional means across parameter values. A plug-in simulation at \(\hat{\theta}\) includes only the conditional outcome variation at that fitted vector. This decomposition concerns the defined simulation distribution; it does not, by itself, say which uncertainty sources are scientifically relevant.
Worked Examples
Worked Example: Steady-State Concentration at a Fitted Clearance
Suppose a hypothetical constant infusion has rate \(R_0=100\) mg/h. Under a one-compartment steady-state calculation, \(C_{\mathrm{ss}}=R_0/CL\), where clearance \(CL\) is in L/h. The fitted clearance is \(\widehat{CL}=5\) L/h. Compare the plug-in prediction with an uncertainty-integrated prediction when the specified uncertainty distribution assigns equal weight to \(CL=4\) and \(CL=6\) L/h.
Conditional target. Substituting the fitted value gives
Integrated target. Evaluate the prediction at each of the two parameter values, then average with their specified weights:
Thus the plug-in prediction is 20 mg/L, while the integrated mean prediction is approximately 20.83 mg/L. The difference occurs because \(100/CL\) is nonlinear in clearance: averaging the concentrations at the two clearances does not equal evaluating concentration at the average clearance. The integrated result describes this specified two-point uncertainty distribution, not every possible distribution around the estimate.
Worked Example: Integrating a Threshold Probability
Use the same hypothetical infusion rate and concentration model, but define event \(A\) as steady-state concentration exceeding 18 mg/L. The fitted clearance is 5 L/h, and the specified parameter distribution gives equal probability to \(CL=4\), 5, and 6 L/h. Assume there is no additional outcome randomness in this calculation.
At the fitted value, \(C_{\mathrm{ss}}=100/5=20\) mg/L, which exceeds the threshold. Since the calculation is deterministic conditional on the parameter, \(P(A\mid CL=5)=1\).
For the integrated probability, calculate the event at each parameter value. At 4 L/h, concentration is \(100/4=25\) mg/L, so the event occurs. At 5 L/h, it is 20 mg/L, so the event occurs. At 6 L/h, it is \(100/6=16.667\) mg/L, so the event does not occur. Therefore,
The conditional probability is 1, whereas the integrated probability is about 0.667 under the stated distribution. This is not a contradiction: the first answers the question at the fitted clearance; the second averages the event indicator over the three specified clearances.
Worked Example: Separating Conditional and Integrated Outcome Variance
Consider a hypothetical endpoint with two equally weighted parameter settings. At the first setting, \(Y\) has conditional mean 10 units and variance 4 units squared; at the second, its conditional mean is 20 units and its conditional variance is also 4 units squared. Calculate the integrated mean and variance, and compare them with the conditional variance at the first setting.
The integrated mean is the average of the two conditional means:
The average conditional variance is 4 units squared. The variance of the two conditional means, each with probability one-half, is
Therefore the integrated outcome variance is \(4+25=29\) units squared. At the first parameter setting alone, the outcome variance is 4 units squared. The additional 25 units squared arises because the conditional means differ across the parameter settings. It is included only when the target averages across those settings.
Designing and Checking a Simulation
The simulation design should match the target in its estimand, not merely in its software implementation. For a conditional target, hold the parameter vector at \(\hat{\theta}\) and simulate any outcome randomness that the target includes. For an integrated target, generate parameter values according to the specified \(q(\theta)\), evaluate the scenario at those values, and average the resulting predictions or outcomes with the appropriate weights.
Specify whether the target is a mean, a distribution, a quantile, or an event probability, and name the scenario and units.
Identify whether parameters are fixed at \(\hat{\theta}\) or varied under \(q(\theta)\), and whether the outcome has additional stochastic variation.
For a plug-in target, calculate at \(\hat{\theta}\). For an integrated target, average conditional predictions or outcomes over the specified parameter distribution.
Record the fitted vector or parameter distribution, scenario, simulated quantity, and averaging rule. Check that the reported result corresponds to those choices.
When the integration is approximated with \(M\) equally weighted parameter draws \(\theta^{(1)},\ldots,\theta^{(M)}\), an estimate of the integrated mean is
For unequal weights \(w_j\) that sum to one, use \(\sum_{j=1}^{M} w_j m(s,\theta^{(j)})\). This numerical average estimates the defined integral; its precision depends on the parameter draws and the simulation procedure. A finite simulation therefore has Monte Carlo error even when the target itself is clearly specified.
Diagnostics, Alternatives, and Limitations
A practical diagnostic is to compare the documented target with the actual inputs to the simulation. If the report calls an output uncertainty-integrated but every replicate uses the same \(\hat{\theta}\), the design has not integrated parameter uncertainty. Conversely, if parameter values vary, identify the distribution and weights that determine what average is being estimated. For a simulated mean, compare estimates from increasing numbers of draws or independent runs to assess whether Monte Carlo variation is material.
A scenario grid is a useful alternative when the goal is sensitivity analysis: calculate outputs at several deliberately chosen parameter values and show how the result changes. But a grid alone is not an uncertainty-integrated estimate. It becomes an approximation to one only when its points and weights represent a specified \(q(\theta)\). Likewise, a plug-in prediction is often simpler and directly answers the question at the fitted estimate, but it does not describe variation across parameter uncertainty.
Neither target is automatically superior. A plug-in target can be appropriate when the question explicitly conditions on the fitted model. An integrated target is appropriate when the intended quantity averages over parameter uncertainty as represented by \(q(\theta)\). The integrated result is only as meaningful as that distribution and the model over the parameter values it covers. It should not be described as accounting for all uncertainty or variability unless the simulation actually includes those sources and the target defines them.
Common Pitfall
Wrong reasoning: “I simulated many subjects with residual error, so my output includes parameter uncertainty.” More subjects or more residual draws at one fixed parameter vector improve the representation of the conditional outcome distribution, but do not vary the parameter vector. Correction: name each source of randomness that is included and check whether the simulation varies \(\theta\) according to \(q(\theta)\). The number of outcome replicates cannot substitute for parameter draws.
Check Your Understanding
Answer each question by identifying the target and showing the essential calculation. Solutions follow.
- A model predicts \(m(\theta)=2\theta\). The fitted value is \(\hat{\theta}=3\), and \(q(\theta)\) assigns equal weight to 2 and 4. What are the conditional and integrated mean predictions?
- At a fitted parameter vector, the model predicts an event probability of 0.30. A simulation generates many outcomes at that fixed vector. Does this estimate an uncertainty-integrated event probability? Explain.
- Two equally weighted parameter settings give conditional means of 4 and 8 units, and conditional variances of 1 unit squared at both settings. Find the integrated mean and variance.
- A report averages predictions from five parameter settings but gives no weights or description of how the settings were chosen. What can be concluded about its target, and what information is missing?
Solutions. 1. The conditional prediction is \(2(3)=6\). The integrated prediction is \(\{2(2)+2(4)\}/2=(4+8)/2=6\); equality here occurs because the prediction is linear in \(\theta\) and the weighted mean parameter is 3. 2. No. It estimates the event probability conditional on the fitted vector; an integrated probability requires averaging conditional event probabilities over a specified parameter distribution. 3. The integrated mean is \((4+8)/2=6\) units. The variance of the conditional means is \(\{(4-6)^2+(8-6)^2\}/2=4\) units squared, so the integrated variance is \(1+4=5\) units squared. 4. The output is an average of five predictions, but its interpretation as an uncertainty-integrated target cannot be established. The weights and the rule or distribution that produced the parameter settings are needed.