Modelling non-standard longitudinal outcomes using fast Bayesian inference.


Repeated observations over time on individual patients allows the opportunity to analyse factors that influence the changes over time in a variable of interest. For example, we may be interested in how a particular treatment received influences the level of a particular blood biomarker, or a count of the number of seizures experienced. Many longitudinal outcomes are commonly analysed using generalised linear mixed models. Bayesian methods such as the popular Markov Chain Monte Carlo (MCMC) are a common way of estimating parameters in such models.

Most current software for modelling longitudinal outcomes is limited to a few standard types of outcomes, such as Gaussian models for continuous data, Bernoulli models for binary data and Poisson models for counts. However, other types of outcomes are possible including categorical and ordinal outcomes or binary and count variables that display overdispersion (more variability than would be expected given the standard Bernoulli or Poisson models). Models exist within the statistical literature to account for these various features of outcome data.

However, in large datasets many of these models can be computationally prohibitive to fit, with MCMC approaches taking a very long time to fit. One potential solution to this is through techniques such as Variational Bayes inference. These approaches aim to develop approximate solutions to the desired posterior distribution by using products of simpler distributions, and can often provide very accurate solutions much more quickly than MCMC.

This project will aim to develop variational approximations for various non-standard longitudinal outcomes. Possible types of outcomes include ordinal and multinomial models for categorical longitudinal outcomes, discrete Weibull models for overdispersed counts, and beta-binomial models for overdispersed binary variables.

In each case models will be tested using extensive simulation studies, and through analysis of real large datasets, to allow for a thorough assessment of the speed gains, and the accuracy of the variational approach. Examples of clinical applications for this work include the use of ordinal mixed models for analysing changes in diabetic retinopathy screening grading over time, and the use of discrete Weibull models to assess overdispersion in counts of seizures over time in epilepsy patients. The project could also consider inclusion of survival data with non-standard longitudinal outcomes within a joint modelling framework. A useful contribution of the project will be the production of R code to allow users to fit these advanced models.


Open to students worldwide

Funding information

Self-funded project



Ormerod, J.T. and Wand, M.P., 2010. Explaining variational approximations. The American Statistician, 64(2), pp.140-153.
Hughes, D.M., García-Fiñana, M. and Wand, M.P., 2023. Fast approximate inference for multivariate longitudinal data. Biostatistics, 24(1), pp.177-192.