Joint Models with Multiple Markers and Multiple Time-to-event Outcomes Using Variational Approximations

Benjamin Christoffersen, Keith Humphreys, Alessandro Gasparini, Birzhan Akynkozhayev, Hedvig Kjellström, Mark A. ClementsarXiv 2025 · DOI

TL;DR

Joint models that track both longitudinal biomarkers and survival outcomes are powerful but notoriously slow to compute for large, complex datasets. This paper introduces a Gaussian Variational Approximation (GVA) method paired with a custom sparse quasi-Newton optimizer to drastically speed up these models. The approach successfully scales to handle multiple markers, competing risks, and tens of thousands of patients while maintaining high accuracy.

What Problem Does This Paper Address?

In medical research, it is common to link health registries (which track time-to-event outcomes like heart attacks or death) with laboratory data (which track longitudinal biomarkers over time, like cholesterol levels). Joint models are the gold standard for analyzing this data because they account for the dependence between a patient's changing biomarkers and their risk of an event.

However, existing frequentist tools for joint modeling hit a computational wall when models become complex. Specifically, calculating the likelihood involves intractable integrals that scale terribly. If a researcher wants to model (a) multiple markers simultaneously, (b) multiple types of survival outcomes (e.g., competing risks or recurrent events), (c) delayed entry (patients entering a study late), and (d) large patient cohorts, standard methods like numerical integration (quadrature) or Markov Chain Monte Carlo (MCMC) become prohibitively slow or simply run out of memory.

Methods

To bypass the computational bottleneck of exact integration, the authors propose using a Gaussian Variational Approximation (GVA).

  • The Standard Setup: The authors use Multivariate Linear Mixed Models (LMMs) for the longitudinal markers and flexible parametric proportional hazards models for the survival outcomes.
  • The Novelty (GVA): Instead of trying to calculate the exact, intractable marginal likelihood, GVA approximates it by finding a strict lower bound. This transforms a nasty integration problem into a high-dimensional optimization problem.
  • Custom Optimization: Because the variational parameters scale with the number of patients, the optimization problem becomes massive. However, the authors exploit the fact that the problem is "partially separable" (it can be broken down per patient). They implemented a tailored quasi-Newton method that preserves the sparsity of the Hessian matrix, allowing for lightning-fast computation.
  • Delayed Entry: To handle delayed entry (left truncation), the authors use adaptive Gauss-Hermite quadrature (AGHQ) specifically for the delayed entry terms, blending exact numerical methods with the variational approximation.

Datasets

  • Simulated Datasets: Custom-generated datasets to test univariate and multivariate scenarios, with and without delayed entry, to benchmark speed and accuracy.
  • pbc2 Dataset: A well-known benchmark dataset of 154 patients with Primary Biliary Cholangitis, tracking 3 longitudinal variables. Used to compare the new method against the existing joineRML package.
  • KARMA Project Dataset: A massive, real-world breast cancer dataset featuring 60,081 women and 188,037 longitudinal mammography measurements (dense and fatty tissue areas) to predict the time to first breast cancer diagnosis.

Key Insights and Ideas

  • Variational Inference for Frequentist Models: Variational inference is traditionally a Bayesian machine learning trick. Here, the authors brilliantly apply it to approximate the frequentist maximum likelihood estimator, proving it yields almost zero bias for these complex joint models.
  • Sparsity is the Key to Scale: Standard optimization algorithms (like BFGS) fail here because storing the Hessian matrix for thousands of patients requires too much memory. By recognizing the "arrowhead" sparse structure of the problem, the authors' custom solver bypasses this limit entirely.
  • Breaking the Curse of Dimensionality: Standard quadrature scales at $O(b^R)$ (where $b$ is the number of nodes and $R$ is the number of random effects). GVA completely sidesteps this exponential explosion, making models with high-dimensional random effects computationally feasible.

Key Results

  • Massive Speedups: In simulations, the GVA approach was two orders of magnitude faster than exact methods. For a univariate model, GVA took ~2 seconds, compared to ~224 seconds for the JM package (exact quadrature) and ~719 seconds for joineRML (Monte Carlo EM).
  • High Accuracy: Despite being an approximation, the GVA estimates showed virtually no bias compared to exact methods, and the lower bound was remarkably close to the true full likelihood.
  • Real-World Scalability: The authors successfully fit a joint model on the massive KARMA dataset involving over 300,000 parameters in just 1.17 hours. A more complex version of the model with random slopes (over 841,000 parameters) converged in ~38 hours—a scale previously unthinkable for frequentist joint models.

Limitations and Future Work

  • Limitations: The current implementation only supports continuous, conditionally normally distributed longitudinal variables. Additionally, handling delayed entry still relies on AGHQ, which slows down the otherwise blazing-fast GVA approach. The authors also noted minor bias in estimating the scale parameter for log-normal frailties.
  • Future Work: The authors plan to extend the framework to Generalized Linear Mixed Models (GLMMs) to handle non-continuous markers (like binary or count data). They also suggest adding support for left-censoring and interval-censoring, and exploring inexact Newton methods to reduce computation time even further.

Summary updated

BibTeX
@misc{christoffersen2025joint,
  author = {Benjamin Christoffersen and Keith Humphreys and Alessandro Gasparini and Birzhan Akynkozhayev and Hedvig Kjellström and Mark A. Clements},
  title = {{Joint Models with Multiple Markers and Multiple Time-to-event Outcomes Using Variational Approximations}},
  year = {2025},
  eprint = {2512.13962},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2512.13962},
  howpublished = {arXiv},
}
Figure