Why the Transition Distribution Matters
In the parametric g-formula, a continuous covariate is not just a value to predict: its conditional distribution determines which future histories are generated. A model that estimates a plausible conditional mean can still generate implausible values or misrepresent the probability of extreme values. Those differences matter whenever later covariate transitions or the outcome depend on the generated covariate.
Let \(L_t\) be a continuous time-varying covariate at time \(t\), \(A_t\) the treatment at that time, and \(V\) baseline covariates. Write the observed history before \(L_t\) as \(H_t=(V,\bar L_{t-1},\bar A_{t-1})\), where bars denote histories through the indicated time. A parametric transition model specifies a conditional distribution for \(L_t\) given \(H_t\) and, when appropriate, the current treatment \(A_t\). Under a regime, the model is evaluated at the treatment value prescribed by that regime.
This tutorial concerns the choice of that conditional distribution. It does not replace the assumptions needed to identify the g-formula: in particular, the causal interpretation still requires the identification conditions established in the earlier material on sequential exchangeability and positivity. For the parametric calculation to represent the identified functional, the transition distributions used in that functional must also be correctly specified, or sufficiently accurate for the target being estimated.
Common Distributional Choices
A Gaussian transition is convenient when conditional variation is roughly symmetric and the variable can take values on the full real line. A typical model is \(L_t\mid H_t,A_t\sim N\{\mu_t(H_t,A_t),\sigma_t^2\}\). Here \(\mu_t(H_t,A_t)\) is the conditional mean and \(\sigma_t^2\) the conditional variance. If a positive-valued variable is modeled this way, however, the fitted distribution assigns positive probability to negative values whenever \(\sigma_t>0\). That may be a serious support mismatch.
For a strictly positive covariate, one option is to model its logarithm as Gaussian. If \(\log L_t\mid H_t,A_t\sim N\{\mu_t(H_t,A_t),\sigma_t^2\}\), then \(L_t\) is conditionally lognormal. Its median is \(\exp(\mu_t)\), but its mean is \(\exp(\mu_t+\sigma_t^2/2)\). Thus, exponentiating a fitted mean on the log scale does not in general give the mean on the original scale.
Other families can better match the variable’s support or shape. A gamma distribution is positive and can represent right skew. A beta distribution can model values strictly between zero and one, after appropriate handling of exact boundary values if those occur. The family should be chosen in light of the variable’s meaning and observed conditional distribution, not merely because a particular fitting procedure is familiar.
Worked Examples
Worked Example: A Gaussian Transition for a Positive Covariate
Suppose a covariate such as a laboratory measurement is positive, but a fitted transition model gives \(L_t\mid H_t,A_t\sim N(1,2.25)\) for one history. The conditional mean is \(1\), and the conditional standard deviation is \(\sqrt{2.25}=1.5\). What does this model imply about negative simulated values?
Standardizing the threshold zero gives \((0-1)/1.5=-2/3\). If \(\Phi\) denotes the standard normal cumulative distribution function, then \(P(L_t<0\mid H_t,A_t)=\Phi(-2/3)\approx 0.2525\). Thus, about one quarter of draws at this history are negative, even though the covariate cannot be negative in reality. This is not a minor issue of presentation: a negative draw may be passed to later transition or outcome models and affect the resulting simulated quantities.
The model could still be a useful approximation if the negative probability is negligible over histories relevant to the estimand, but that claim must be checked. Otherwise, consider a transition family with appropriate support, such as a lognormal or gamma model, and assess its fit.
Worked Example: Lognormal Mean and Tail Probability
At a given history, suppose \(\log L_t\mid H_t,A_t\sim N(1,0.36)\), so the log-scale standard deviation is \(0.6\). Calculate the conditional median, mean, and probability that \(L_t\) exceeds 6.
The median is \(\exp(1)\approx2.7183\). The conditional mean is \(\exp(1+0.36/2)=\exp(1.18)\approx3.254\). The mean exceeds the median because the distribution is right-skewed.
For the tail probability, monotonicity of the logarithm gives \(P(L_t>6\mid H_t,A_t)=P\{\log L_t>\log 6\mid H_t,A_t\}\). Standardizing, \((\log 6-1)/0.6\approx1.319599\). Hence the probability is the standard normal upper tail at 1.319599, approximately \(0.09348\) (about \(0.0935\)). This illustrates why the upper tail should be calculated from the fitted distribution rather than inferred from the mean alone.
Worked Example: A Gamma Transition and Its Right Tail
Suppose instead that \(L_t\mid H_t,A_t\) has a gamma distribution with shape \(k=4\) and scale \(\theta=1.5\). Under this parameterization its mean is \(k\theta\) and variance is \(k\theta^2\). Calculate these quantities and the probability that \(L_t>9\).
The mean is \(4(1.5)=6\), and the variance is \(4(1.5^2)=9\), so the standard deviation is \(3\). Since the shape is the integer 4, the gamma upper-tail probability at 9 is \(e^{-9/1.5}\sum_{j=0}^{3}(9/1.5)^j/j!\). The ratio \(9/1.5=6\), so this becomes \(e^{-6}(1+6+18+36)=61e^{-6}\approx0.15120\).
A Gaussian distribution with the same mean and variance would give \(P\{N(6,9)>9\}=P\{Z>1\}\approx0.15866\), where \(Z\sim N(0,1)\). The two choices agree on mean and variance but not on the tail probability or support: the gamma model is positive and right-skewed, whereas the Gaussian model is symmetric and assigns probability to negative values.
Why Conditional Means Are Not the Whole Story
A transition model is used to generate histories, not merely to report a fitted mean. If a later quantity depends on whether a covariate crosses a threshold, its expectation depends on the transition tail. More generally, averaging a function of a random covariate is not usually the same as applying that function to the covariate’s mean. The following identity makes the issue explicit when the later quantity is an indicator.
Justification: The indicator equals one on the event \(L_t>c\) and zero otherwise. Its conditional expectation is therefore \(1\cdot P(L_t>c\mid H_t,A_t)+0\cdot P(L_t\le c\mid H_t,A_t)\), which equals the stated tail probability. In a longitudinal calculation, such a tail difference can change which histories are generated and thus change later conditional expectations. Matching conditional means alone does not ensure matching the transition distribution or the g-formula functional. \(\square\)
Choosing and Checking a Transition Family
A useful choice begins with the covariate’s support and measurement process. A strictly positive concentration, a bounded proportion, and a roughly symmetric change score do not call for the same default family. Then examine whether the conditional spread and shape are adequately represented across histories of interest. A single unconditional histogram can conceal conditional misspecification: for example, a mixture of different conditional means can look skewed even when each conditional distribution is approximately symmetric.
| Transition choice | Support and useful feature | Potential failure |
|---|---|---|
| Gaussian | All real values; symmetric conditional variation | Impossible values for positive or bounded covariates; tails may be too light or too symmetric |
| Lognormal | Strictly positive values; right skew on the original scale | Cannot represent zero or negative values; log-scale normality may be poor |
| Gamma | Strictly positive values; flexible positive, right-skewed shape | May not fit the observed tail or conditional variance pattern |
| Beta | Values strictly between zero and one | Does not directly assign probability to exact zero or one |
Diagnostics should be assessed conditional on relevant histories, not only in aggregate. Useful checks include comparing observed and fitted conditional distributions, examining residual or probability-integral-transform diagnostics, checking simulated quantiles and tail probabilities, and tabulating impossible or extreme generated values. For a transformed model, inspect fit on both the modeled scale and the original scale; a good-looking residual plot for \(\log L_t\) does not by itself establish that the original-scale tail is adequate. Diagnostics can reveal incompatibility or lack of fit, but passing them cannot prove that the assumed family is correct.
A common pitfall is to choose the model with the best-looking conditional-mean fit and assume that it must produce appropriate simulated covariate histories. That conclusion does not follow: a mean model does not determine support, variance, skewness, or tail probabilities. The correction is to compare distributional implications relevant to the target, including whether simulated values are possible and whether the conditional tails are plausible.
A second pitfall is to exponentiate the fitted log-scale mean and call it the original-scale mean. Under a lognormal model, \(\exp(\mu)\) is the conditional median, while the mean is \(\exp(\mu+\sigma^2/2)\). Ignoring this distinction can misstate expected covariate levels, especially when log-scale variance is substantial.
No parametric family is universally best. A Gaussian model may be adequate for a genuinely near-symmetric variable with support extending over the real line; a lognormal or gamma model may be preferable for positive, skewed measurements; and a bounded family may be needed for a bounded variable. Flexible distributional modeling can also require more data and careful estimation. Regardless of family, extrapolation into histories poorly represented in the data remains a limitation, and a well-fitting transition model does not remove the causal identification assumptions.
A Practical Selection Sequence
Determine whether the covariate can be negative, must be positive, is bounded, or can equal a boundary value.
Choose distributions whose support and shape are scientifically plausible, and define how their parameters depend on the observed history.
Compare conditional spread, shape, quantiles, and tails; verify the mean on the original scale when using a transformation.
Look for impossible values, implausible extremes, and histories for which the fitted distribution is extrapolating beyond observed support.
Repeat the target calculation under reasonable transition families and interpret material changes as sensitivity to distributional specification.
Check Your Understanding
Answer each question, then compare with the solutions.
- If \(\log L\mid H\sim N(\mu,\sigma^2)\), which is the conditional median of \(L\), and which is its conditional mean?
- A positive covariate is modeled as \(N(4,1)\). What is the model-implied probability of a negative value?
- Why can two transition models with the same conditional mean produce different expected values of \(I(L>c)\)?
- Name one setting where a beta transition model is natural and one issue that must be addressed if exact boundary values occur.
Solutions. (1) The median is \(\exp(\mu)\); the mean is \(\exp(\mu+\sigma^2/2)\), as follows from the lognormal moment calculation. (2) The standard deviation is 1, so \(P(L<0\mid H)=\Phi((0-4)/1)=\Phi(-4)\approx0.0000317\). This probability is small but not zero. (3) The expectation of the indicator is the tail probability \(P(L>c)\), which depends on the distribution’s shape and spread as well as its mean. (4) A proportion strictly between zero and one is a natural beta outcome. A standard beta distribution assigns probability only to the open interval \((0,1)\), so exact zeros or ones require an explicit modeling strategy rather than being treated as ordinary beta draws.