Why Model HbA1c and Complications Together?
HbA1c is measured repeatedly, while the clinical outcome of interest may be the time until a first microvascular complication. A patient’s recorded values vary around an underlying trajectory, and those values may be observed less often—or stop being observed—when health changes. Relating the event only to a single baseline measurement can discard information about subsequent glycemic control. Relating it to the most recent recorded value can also be problematic when that value is measured with error or when visit timing is informative.
A joint model represents the longitudinal measurements and event time together. In this case study, the event is the first recorded microvascular complication after study entry. Diabetes duration at entry and baseline HbA1c are included explicitly, so the estimated association between the evolving HbA1c level and complication hazard is interpreted conditional on those characteristics. The model estimates an adjusted association, not a causal effect of lowering HbA1c.
A Joint Model for HbA1c and Time to Complication
Let \(Y_{ij}\) be patient \(i\)’s HbA1c measurement at time \(t_{ij}\), measured in years since study entry. HbA1c is expressed in percentage points. Let \(D_i\) be diabetes duration at entry, expressed in units of five years, and let \(B_i\) be baseline HbA1c centered at 7.0 percentage points: \(B_i=\text{baseline HbA1c}_i-7.0\). Centering makes the model’s reference values interpretable; it does not change the underlying information in the data.
One possible longitudinal submodel is a linear mixed model:
The latent mean \(m_i(t)\) is measured in HbA1c percentage points. The random effects \(b_{0i}\) and \(b_{1i}\) allow patients to differ in their underlying level and rate of change. A standard specification assumes \((b_{0i},b_{1i})^\mathsf{T}\sim N(\mathbf{0},\Sigma)\), and \(\varepsilon_{ij}\sim N(0,\sigma^2)\), independently across measurements and independently of the random effects. The interaction \(tD_i\) allows the mean trajectory’s rate of change to vary with diabetes duration. Other trajectory forms may be appropriate if the data show curvature.
Let \(T_i\) be time from entry to the first complication or censoring, and let \(\delta_i=1\) if the complication is observed and \(0\) if the patient is right-censored. A proportional-hazards event submodel using current latent HbA1c is:
Here \(h_0(t)\) is the baseline hazard, \(b_i=(b_{0i},b_{1i})^\mathsf{T}\), and \(h_i(t\mid b_i)\) is the instantaneous complication rate at time \(t\), conditional on being free of the complication just before \(t\). The coefficients \(\gamma_D\) and \(\gamma_B\) describe associations with duration and baseline control after accounting for the latent current HbA1c level. The shared-parameter coefficient \(\alpha\) describes the association of that latent level with the hazard, conditional on the modeled duration and baseline covariates.
Why the Joint Likelihood Uses Both Outcomes
The joint model does not treat each estimated patient trajectory as if it were known exactly. It accounts for uncertainty in the latent random effects while using the event information and longitudinal measurements together. Conditional on the random effects, the longitudinal measurements have their specified measurement distribution, and the event-time contribution is determined by the hazard and survival function. The patient’s likelihood contribution integrates over the random-effects distribution:
The product includes the patient’s observed HbA1c measurements available up to the event or censoring time. The second factor is the right-censored event-time contribution: an observed event contributes a hazard at \(T_i\), while both event and censoring records contribute survival through \(T_i\). Integrating over \(b_i\) accounts for uncertainty about each patient’s trajectory. The shared random effects and current latent value connect the two outcomes.
This formulation relies on substantive assumptions. The longitudinal mean and residual distribution must adequately describe the trajectory and measurement noise; the hazard must have the stated relationship to the latent trajectory and covariates; and censoring must be noninformative conditional on the modeled information. The proportional-hazards form assumes the covariate effects in the exponent do not change over time. The model also presumes the event definition and time origin are consistently applied. If death prevents observation of a microvascular complication, treating death as ordinary independent censoring may be inappropriate; a competing-risks approach may be needed for the scientific question.
Worked Example: Calculating an Underlying HbA1c Value
Suppose a hypothetical fitted longitudinal model has \(\beta_0=7.40\), \(\beta_t=0.06\), \(\beta_D=0.18\), \(\beta_B=0.25\), and \(\beta_{tD}=-0.03\). For a patient with 10 years of diabetes at entry, baseline HbA1c of 8.0%, posterior random-effect estimates \(b_{0i}=0.20\) and \(b_{1i}=-0.08\), calculate the fitted underlying HbA1c at two years after entry.
The patient has \(D_i=10/5=2\) and \(B_i=8.0-7.0=1.0\). Substitute these values and \(t=2\):
The fitted underlying value is 8.05% HbA1c. It is not the patient’s raw observed measurement; it is the model-based trajectory value, conditional on the stated parameter and random-effect estimates. The negative random slope in this example lowers the fitted value at two years relative to the patient’s random intercept.
Interpreting the Estimated Association
Because \(m_i(t)\) is measured in HbA1c percentage points, \(\alpha\) is a log hazard ratio per one-percentage-point higher latent HbA1c. For two otherwise identical patients at the same time, a difference of \(\Delta\) percentage points in their underlying HbA1c implies a conditional hazard ratio of \(\exp(\alpha\Delta)\). This comparison holds diabetes duration and baseline HbA1c fixed. It does not compare cumulative probabilities of complications, and a hazard ratio is not a risk ratio.
Worked Example: A Hazard Ratio and Confidence Interval
Suppose a hypothetical joint-model fit estimates \(\hat{\alpha}=0.28\), with \(SE(\hat{\alpha})=0.09\). Calculate and interpret the hazard ratio for a one-percentage-point higher underlying HbA1c, and a 95% confidence interval.
The hazard ratio is \(\exp(0.28)=1.323\). Thus, conditional on the modeled diabetes duration and baseline HbA1c, a one-percentage-point higher latent HbA1c is associated with an estimated 32.3% higher instantaneous complication hazard.
On the log-hazard scale, the approximate 95% confidence interval is \(0.28\pm1.96(0.09)\). The margin is \(0.1764\), so the interval is \((0.1036,0.4564)\). Exponentiating its endpoints gives:
The estimated 95% confidence interval for the hazard ratio is 1.109 to 1.578. Under the model and its repeated-sampling assumptions, the interval procedure has 95% coverage; it is not a statement that this particular interval has a 95% probability of containing the fixed parameter. Because the interval excludes 1, the estimate is inconsistent with a zero association at the corresponding two-sided 5% level under the model. The interval still does not establish a causal effect.
Duration and baseline control matter for interpretation because their coefficients represent additional modeled associations. If duration is coded in five-year units, \(\exp(\gamma_D)\) is the hazard ratio for five additional years of diabetes at the same baseline HbA1c and latent current HbA1c. Similarly, \(\exp(\gamma_B)\) is the hazard ratio for a one-percentage-point higher baseline HbA1c at the same duration and latent current value. Those conditional comparisons should not be confused with the overall differences between patients whose duration, baseline control, and evolving HbA1c all differ.
Worked Example: Separating Three Model Contributions
Suppose a hypothetical fitted event model has \(\hat{\gamma}_D=0.16\) per five years, \(\hat{\gamma}_B=0.10\) per baseline percentage point, and \(\hat{\alpha}=0.28\) per current latent percentage point. Compare two patients at the same follow-up time. Patient A has 5 years of diabetes, baseline HbA1c 7.0%, and latent current HbA1c 8.0%. Patient B has 15 years of diabetes, baseline HbA1c 8.0%, and latent current HbA1c 9.0%.
The differences are \(\Delta D=2\) five-year units, \(\Delta B=1\) percentage point, and \(\Delta m=1\) percentage point. The model’s log hazard contrast for B versus A is:
Therefore the conditional hazard ratio is \(\exp(0.70)=2.014\). Under this fitted model, Patient B has about 2.01 times the instantaneous complication hazard of Patient A at that time. This modeled contrast combines duration, baseline control, and current latent HbA1c; it is not the hazard ratio for HbA1c alone. If duration and baseline control were instead held fixed and only current latent HbA1c differed by one percentage point, the hazard ratio would be \(\exp(0.28)=1.323\).
Diagnostics, Alternatives, and Limitations
A fitted joint model should be assessed rather than accepted solely because it converged. Examine whether the longitudinal mean captures the observed trajectory patterns across follow-up and across duration and baseline-control groups. Residual plots can reveal curvature, unequal residual variance, or outlying measurements. Check whether the random-effects distribution and covariance structure are plausible, and whether fitted event predictions align with observed event patterns. A time-varying effect or a non-linear trajectory may be needed if the proportional-hazards or linear-time assumptions are not credible. Convergence warnings, unstable estimates, or sensitivity to starting values can indicate weak information or an overly complex model.
The current-value association used here is not the only possible link. A model can instead link hazard to a latent slope, or to both current value and slope, if that better matches the scientific question and is supported by the data. These alternatives answer different questions: a slope association concerns the rate of HbA1c change, not simply the level. They also require careful interpretation and adequate information to estimate their parameters.
A Cox model using baseline HbA1c and duration is simpler but does not represent subsequent marker evolution. A Cox model using the most recently observed HbA1c as a time-dependent covariate can use repeated measurements, but typically treats that observed value as the relevant covariate and may not account for measurement error or the marker’s latent trajectory. A landmark analysis relates information available at a selected time to later outcomes, but its target is conditional on reaching that landmark event-free. The joint model’s advantage is a direct link between the estimated trajectory and event hazard; its cost is stronger modeling assumptions and more demanding estimation.
The association can still be affected by unmeasured confounding, model misspecification, selection into the cohort, and informative visit patterns not handled by the model. Including duration and baseline control does not guarantee that all relevant differences between patients have been controlled. The interpretation is conditional on the specified covariates, trajectory, hazard, censoring, and random-effects assumptions.
Common Pitfall
- Wrong reasoning: “The estimated hazard ratio is 1.32 per percentage point, so lowering a patient’s HbA1c by one point will reduce that patient’s complication risk by 32%.” This turns a conditional hazard association into a causal effect and also confuses hazard with risk.
- Correction: The fitted model estimates a conditional association between latent HbA1c and instantaneous hazard, given modeled duration and baseline control. Causal claims require additional assumptions and design or analysis strategies; a hazard ratio alone does not identify the effect of an intervention.
Check Your Understanding
Answer each question, then compare with the concise solutions below.
- If \(\hat{\alpha}=0.20\), what is the hazard ratio for a one-percentage-point higher latent HbA1c?
- In the stated coding, what does \(\exp(\gamma_D)\) compare?
- Why might a model based only on the last observed HbA1c be inadequate?
- State one assumption that could fail if death prevents a patient from experiencing an observed first microvascular complication.
Solutions. (1) \(\exp(0.20)=1.221\), or about a 22.1% higher conditional instantaneous hazard per percentage point. (2) It is the conditional hazard ratio for five additional years of diabetes, holding baseline HbA1c and current latent HbA1c fixed. (3) The last observed value may contain measurement error and may not represent the underlying trajectory; its observation time may also be informative. (4) Treating death as ordinary independent censoring may fail because death can preclude the complication; competing risks may need consideration.