Processing math: 100%

Mixed Models for Repeated Measures

Abstract

Mixed models for repeated measures (MMRMs) are frequently used in the analysis of data from clinical trials. They are specifically suited to model continuous variables that were repeatedly measured at discrete time points (or within defined time-windows). In a clinical trial, these time points are typically visits according to a schedule that is pre-defined in the trial protocol. The distinguishing feature of MMRMs, compared to other implementations of linear mixed models, is that subject-specific random effects (which are not of direct interest for estimation and inference) are considered as residual effects, i.e. they are part of the error correlation matrix. This vignette provides a brief methodological introduction to MMRMs. MMRMs are described as an extension to a basic linear mixed-effects model. The aim is to provide a basic orientation and guide for applied statisticians working in the field of clinical trials regarding theoretical underpinnings of MMRMs and practical use in clinical trials. In the descriptions of the models below, we generally follow Pinheiro and Bates (2000) and C. Mallinckrodt and Lipkovich (2017).

The basic linear mixed-effects model

Laird and Ware (1982) introduced the basic linear mixed-effects model for a single level of grouping to be any model that expresses an ni-dimensional response (column) vector yi for the ith subject (or, more generally, group or unit) as yi=Xiβ+Zibi+ϵi,i=1,,M,biN(0,Ψ),ϵiN(0,σ2I), where

The random effects bi and the within-group errors ϵi are assumed to follow a normal distribution, with means of 0 and variance-covariance matrices Ψ and σ2I, where I is an identity matrix. They are further assumed to be independent for different subjects and independent of each other for the same subject. The random effects bi describe the shift from the mean of the linear predictor for each subject. As they are defined to have a mean of 0, any non-zero mean for a term in the random effects must be expressed as part of the fixed-effects terms. Therefore, the columns of Zi are usually a (small) subset of the columns of Xi.

Mixed models are called “mixed” because they consider both fixed and random effects and thus allow considerable modeling flexibility. This is the case even for the basic formulation described above. However, it still restricts within-group errors to be independent, identically distributed random variables with mean of zero and constant variance. These assumptions may often be seen as too restrictive (unrealistic) for applications. For example, in the case of clinical trials with repeated measurements of subjects over time, observations are not independent and within-subject correlation needs to be accounted for by the model.

Extending the basic linear mixed-effects model

The basic linear mixed-effects model can be extended in order to incorporate within-subject errors that are heteroscedastic (i.e. have unequal variances) and/ or are correlated. For this purpose, we can express the within-subject errors as: ϵiN(0,Λi),i=1,,M, where the Λi are positive-definite matrices parameterized by a fixed, generally small set of parameters λ. As in the basic model, the within-group errors ϵi are assumed to be independent for different i and independent of the random effects bi. The variance-covariance matrix of the response vector yi, Var(yi)=Σi=(ZiΨZTi+Λi), comprises a random-effects component, given by ZiΨZTi, and a within-subject component, given by Λi. When fitting such models, there will generally be a “competition” and trade-off between the complexities of the two components, and care must be exercised to prevent nonidentifiability, or near nonidentifiability, of the parameters. This is one of the reasons why it can be advantageous in practice to use only one of these components as long as it still allows to capture all relevant sources of variability. In longitudinal studies with only one level of grouping, the within-subject component is particularly important to be considered in order to account for within-subject correlation, whereas an additional random-effects component is often not strictly needed.

Of note, in the literature, the random-effects component and the within-subject component are sometimes also referred to as R and G, or as R-side and G-side random effects (Cnaan, Laird, and Slasor (1997), Littell, Pendergast, and Natarajan (2000)).

The MMRM as a special case

In a clinical trial setting, one often chooses to directly model the variance-covariance structure of the response, i.e. to account for within-subject dependencies using the within-group component Λi, and can omit the random effects component (Zibi). Hence, in this case, Var(yi)=Σi=Λi . This yields the MMRM with:

yi=Xiβ+ϵi,ϵiN(0,Σi),i=1,,M.

The Σi matrices are obtained by subsetting the overall variance-covariance matrix ΣRm×m, where m is the total number of scheduled visits per subject, appropriately by Σi=SiΣSi, where Si{0,1}m×mi is the subject-specific ‘’subsetting matrix’’ that indicates the visits with available observations (see also the vignette on the Details of the Model Fitting in mmrm).

When written as a model for all n subjects in a trial, the MMRM is represented by Y=Xβ+ϵ, where YRN combines all subject-specific observations yi such that in total there are N=ni=1mi observations, XRN×p combines all subject-specific design matrices, βRp is a vector of fixed effects, and ϵRN has a multivariate normal distribution, ϵN(0,Ω), with ΩRN×N being a block-diagonal matrix, containing the subject-specific Σi on the diagonal (and with all other entries being equal to 0).

When modeling longitudinal responses in a clinical trial with multiple follow-up visits, the linear predictor Xβ typically considers fixed effects of baseline values, treatment and visit, as well as interactions between treatment and visit, and possibly between baseline and visit. Commonly the fixed effects are of most interest and the correlation structure Σ can be viewed as a nuisance quantity. However, it is important to model it carefully, since it affects validity of the estimated variance of β. The mmrm package supports a wide range of covariance structures (see also the vignette on Covariance Structures in mmrm).

Missing data

Mixed models can accommodate unbalanced data and use all available observations and subjects in the analysis. Inferences are valid under the assumption that missing observations are independent of unobserved data, but may be dependent on observed data. This assumption that is often seen as reasonable and is called “missing at random”-assumption. By contrast, some imputation methods to handle missing data and modeling alternatives, such as the last-observation carried forward-approach or models based on generalized estimating equations, require stricter assumptions on missingness mechanism (C. H. Mallinckrodt, Lane, Schnell, Peng, and Mancuso (2008), Fitzmaurice (2016)).

References

Cnaan A, Laird NM, Slasor P (1997). Using the general linear mixed model to analyse unbalanced repeated measures and longitudinal data.” Statistics in Medicine, 16(20), 2349–2380.
Fitzmaurice GM (2016). Generalized Estimating Equations.” In Wiley StatsRef: Statistics Reference Online 1–4. John Wiley & Sons, Ltd.
Laird NM, Ware JH (1982). Random-effects models for longitudinal data.” Biometrics, 38(4), 963–974.
Littell RC, Pendergast J, Natarajan R (2000). Modelling covariance structure in the analysis of repeated measures data.” Statistics in Medicine, 19(13), 1793–1819.
Mallinckrodt CH, Lane PW, Schnell D, Peng Y, Mancuso JP (2008). Recommendations for the Primary Analysis of Continuous Endpoints in Longitudinal Clinical Trials.” Drug Information Journal, 42(4), 303–319.
Mallinckrodt C, Lipkovich I (2017). Analyzing Longitudinal Clinical Trial Data. A Practical Guide. Chapman & Hall/ CRC Biostatistics Series.
Pinheiro J, Bates DM (2000). Mixed-Effects Models in S and S-PLUS. Springer (Statistics; Computing).