Why Occasion Counts Matter
Interoccasion variability (IOV) describes variation in a model parameter from one occasion to another for the same subject. Estimating it requires repeated occasions: a subject observed on only one occasion cannot directly show how that subject’s parameter changes across occasions. When subjects have unequal numbers of occasions, each contributes a different amount of within-subject information. The total number of observations alone therefore does not describe the information available for IOV.
A useful way to make this precise is to study within-subject contrasts. The likelihood in this tutorial is a deliberately simplified, exact variance-component calculation: it assumes a known residual variance and occasion-level observations on a common scale. A full population PK analysis may instead fit the structural and observation models jointly. The contrast calculation nevertheless makes the role of unequal occasion counts clear.
The constant \(a_i\) can include a population level and a subject-specific level that does not change between occasions. It disappears when observations are centered within subject. Define \(\bar{Y}_i=m_i^{-1}\sum_{j=1}^{m_i}Y_{ij}\), and let \(Q=\sum_i\sum_{j=1}^{m_i}(Y_{ij}-\bar{Y}_i)^2\). Subject \(i\) contributes \(m_i-1\) independent contrast degrees of freedom, so the total is \(\nu=\sum_i(m_i-1)\). A subject with one occasion contributes zero.
Likelihood and the Constrained Estimate
After centering within subject, the contrast sum of squares has the distribution \(Q/v\sim\chi^2_\nu\), provided \(\nu>0\) and the model assumptions hold. Thus, apart from factors that do not depend on \(v\), the likelihood is
The constraint \(v\geq r^2\) follows from \(v=\theta+r^2\) and \(\theta\geq0\). Taking the log likelihood and differentiating gives
where \(C\) does not depend on \(v\). When \(Q>0\), the derivative is positive for \(v<Q/\nu\) and negative for \(v>Q/\nu\). Therefore the unconstrained maximum is \(Q/\nu\). Applying the lower bound \(r^2\) gives the constrained estimates
This formula applies when \(Q>0\) or \(r^2>0\). The zero case needs care: if \(Q=0\), the likelihood is proportional to \(v^{-\nu/2}\). If \(r^2>0\), it is maximized at the allowed boundary \(v=r^2\), giving \(\hat{\theta}=0\). If \(Q=r^2=0\), the likelihood grows without bound as \(v\) decreases toward zero. There is then no finite, attained maximum-likelihood estimate. In particular, it is not correct to call \(Q/\nu=0\) an attained unconstrained maximum in this case.
Worked Likelihood Comparisons
Worked Example: Balanced Occasion Counts
Suppose four hypothetical subjects each have three occasions. The within-subject sums of squares are \(Q_i=3,\ 4,\ 5,\) and \(6\), in squared log-parameter units. Assume the known residual variance is \(r^2=1\) in those squared units.
Each subject contributes \(3-1=2\) degrees of freedom, so \(\nu=4(2)=8\). The total is \(Q=3+4+5+6=18\). The unconstrained total-variance estimate is \(Q/\nu=18/8=2.25\), which exceeds the lower bound \(r^2=1\). Therefore
\(\hat{\theta}=18/8-1=1.25\) squared log-parameter units.
For a sense of uncertainty, a 95% confidence interval for \(v\), before enforcing its parameter-space bound, follows by inverting \(Q/v\sim\chi^2_8\). Using the 2.5th and 97.5th percentiles \(2.180\) and \(17.535\), respectively, gives \(18/17.535=1.027\) to \(18/2.180=8.257\). Subtracting \(r^2=1\) and restricting to \(\theta\geq0\) gives approximately \(0.027\) to \(7.257\) squared log-parameter units. This wide interval indicates that a positive point estimate need not imply a precisely estimated variance.
Worked Example: Unequal Occasion Counts
Now consider four hypothetical subjects with occasion counts \(4,\ 3,\ 2,\) and \(1\). Their within-subject sums of squares are \(6,\ 4,\ 5,\) and \(0\), respectively, and \(r^2=1\) squared log-parameter units.
The degrees of freedom are \((4-1)+(3-1)+(2-1)+(1-1)=3+2+1+0=6\). The single-occasion subject contributes no within-subject contrast. The total contrast sum of squares is \(Q=6+4+5+0=15\), so \(Q/\nu=15/6=2.5\). Hence \(\hat{\theta}=2.5-1=1.5\) squared log-parameter units.
Using the \(\chi^2_6\) percentiles \(1.237\) and \(14.449\), a corresponding 95% interval for \(v\) is \(15/14.449=1.038\) to \(15/1.237=12.126\). Transforming to \(\theta\) and respecting its nonnegative constraint gives approximately \(0.038\) to \(11.126\) squared log-parameter units. The point estimate is higher than in the balanced example, but the interval is also broad. The different estimate reflects the particular observed \(Q/\nu\), not a general rule that imbalance raises IOV.
Worked Example: Same Degrees of Freedom, Different Allocation
Compare two hypothetical allocations with eight total occasions and \(\nu=5\). In allocation A, three subjects have \(3,\ 3,\) and \(2\) occasions, with within-subject sums of squares \(2,\ 4,\) and \(4\). In allocation B, subjects have \(6,\ 1,\) and \(1\) occasions, with sums of squares \(10,\ 0,\) and \(0\). Let \(r^2=1\) squared units in both cases.
For A, \(\nu=(3-1)+(3-1)+(2-1)=5\), \(Q=2+4+4=10\), and \(\hat{\theta}=10/5-1=1\) squared units. For B, \(\nu=(6-1)+(1-1)+(1-1)=5\), \(Q=10\), and the estimate is again \(\hat{\theta}=1\) squared units. Under the stated likelihood, both allocations have the same likelihood for every \(v\), since both have the same \(Q\) and \(\nu\).
That equality is specific to this model and these summaries. Allocation B concentrates all contrast information in one subject; it therefore offers fewer subjects with repeated observations for checking whether the model is a reasonable description across subjects. Equal likelihood information in this calculation does not mean the allocations are equally useful for every modeling or diagnostic purpose.
What Unequal Counts Change in Practice
For a fixed number of subjects, an additional occasion on a subject with repeated observations adds one contrast degree of freedom. If an occasion count is \(m_i\), its direct contribution is \(m_i-1\); counts should not be averaged first and treated as if every subject had the average number. Subjects with only one occasion may inform other parts of a population model, but they do not contribute to this within-subject variance likelihood.
In the simplified model, two designs with the same \(\nu\) and \(Q\) have the same likelihood for \(\theta\), even if their occasion counts are allocated differently. In actual PK data, however, occasion-level information can vary with sampling times, dose histories, missingness, and the precision of the structural-model predictions. The variance may then need to be estimated in a joint likelihood rather than by pooling raw within-subject contrasts. Unequal counts can also leave few subjects with repeated observations, make a result sensitive to one subject, or coincide with informative missingness. The contrast formula alone cannot address those issues.
Assumptions, Diagnostics, and Alternatives
The calculation requires independent, normally distributed occasion effects with a common variance; independent normal residual errors with known common variance \(r^2\); a stable subject-specific level across occasions; and comparable measurements on a common scale. It also assumes the occasions being compared are exchangeable with respect to the modeled occasion effect. If the measurement scale changes by subject, occasion, or sampling design, a common-variance contrast likelihood may not be appropriate. In particular, estimated residual variance cannot simply be treated as known without accounting for its uncertainty.
Useful checks include inspecting each subject’s contribution \(Q_i=\sum_j(Y_{ij}-\bar{Y}_i)^2\), looking for an estimate at \(\hat{\theta}=0\), and checking whether a small number of subjects dominates \(Q\). A boundary estimate means the data do not support a positive IOV variance beyond the assumed residual variance under this model; it does not prove that biological occasion variability is absent. A large contribution from one subject may point to unusual observations or a model mismatch and should be investigated rather than automatically discarded. A likelihood profile or an interval is more informative about precision than reporting the point estimate alone.
The contrast likelihood is attractive because it yields a transparent calculation and removes a constant subject-level effect. A method-of-moments estimate uses the same ratio \(Q/\nu\) for total contrast variance, but the likelihood makes the nonnegative variance constraint and boundary behavior explicit. A joint nonlinear mixed-effects likelihood is preferable when occasion-level information must be derived from concentration data, residual variance is estimated, or the structural model needs to be fitted simultaneously. Such a fit uses more of the PK data structure but depends on its own modeling and computational assumptions. Neither approach compensates for a design with too few repeated occasions to identify IOV well.
Record each subject’s \(m_i\); subjects with one occasion contribute no within-subject contrasts.
Compute \(\nu=\sum_i(m_i-1)\) and \(Q=\sum_i\sum_j(Y_{ij}-\bar{Y}_i)^2\).
Use the constrained likelihood estimate, then examine a profile or interval and the subject-level contributions.
Check Your Understanding
Answer each question using the contrast model above. Solutions follow the questions.
- Five subjects each have two occasions. What is \(\nu\), and how many contrast degrees of freedom does each subject provide?
- Suppose \(\nu=4\), \(Q=6\), and \(r^2=1\) squared units. Calculate \(\hat{\theta}\).
- With \(\nu>0\), \(Q=0\), and \(r^2=2\), what is the constrained estimate, and why?
- With \(\nu>0\), \(Q=r^2=0\), is there an attained finite MLE? Explain.
- Two allocations have the same \(Q\) and \(\nu\), but in one allocation most contrasts come from one subject. What does the simplified likelihood imply, and what practical concern remains?
Solutions. (1) \(\nu=5(2-1)=5\); each subject provides one contrast degree of freedom. (2) \(\hat{\theta}=\max(0,6/4-1)=0.5\) squared units. (3) \(\hat{\theta}=0\), because the likelihood decreases as \(v\) increases from the lower bound \(r^2=2\) when \(Q=0\). (4) No. The likelihood is unbounded as \(v\) approaches zero, so there is no attained finite maximum. (5) The simplified likelihood is identical for the two allocations because it depends on \(Q\) and \(\nu\). In practice, concentration of contrasts in one subject means fewer subjects provide repeated-occasion information, so the adequacy of the model and the broader population interpretation deserve scrutiny.