# How to report a linear mixed-effects model equation

I have run a linear mixed-effects model, with one fixed effect (dd) and a random slope and intercept term for individual (fInd) and would like to know how to report the results? In particular, I would like to display the model equation, but I am having trouble working out what to do with the random effects part. Below is my model output using the lme() function in R. The optimal random effects structure was chosen using likelihood ratio tests for models fitted with REML as suggested in Zuur et al (2009):

Model = lme(dtim ~ dd, random= ~1 + dd|fInd, data=df, method="REML")

Linear mixed-effects model fit by REML
Data: df
AIC      BIC    logLik
93024.49 93064.13 -46502.43

Random effects:
Formula: ~1 + dd | fInd
Structure: General positive-definite, Log-Cholesky parametrization
StdDev    Corr
(Intercept) 0.5231033 (Intr)
dd          0.2154805 -0.47
Residual    2.6134946

Fixed effects: dtim ~ dd
Value  Std.Error    DF  t-value p-value
(Intercept) -0.5721233 0.12394717 17600 -3.46132       0
dd           2.2663854 0.04906525 17600 42.14376       0
Correlation:
(Intr)
dd     -0.489

Standardized Within-Group Residuals:
Min         Q1        Med         Q3        Max
-7.0603118 -0.4650351 -0.1982975  0.2412834 14.1304020


If I was displaying the model equation from a linear model without random terms I would write the equation as so:

dtim = 2.266 * dd - 0.572

How would one then include notation to symbolise the random effects terms or are model outputs not reported in this way with mixed-effects models? Any advise would be much appreciated.

• I personally believe that using LRT with REML-estimated models for model selection is wrong. You are not comparing models having the same dependent variable $y_{new}$ as for each model you are using $y_{new} = k^Ty$ where $k^TX=0$ (Searle et al. 1992). Aside that, LRT are not explicitly penalizing for the number of parameters included in the model; and you not even bootstrapping your models. Consider using your models alongside the package RLRsim; it will save a world of statistical pain. – usεr11852 Sep 30 '14 at 23:51
• Interesting..there seems to be a lot of disagreement about this topic. I was under the impression that LRTs to compare different 'random effects structures' were ok as the models are technically nested models, but I will take on board the above. I know there are concerns about using LRTs to find optimal fixed effects structures (Pinheiro & Bates,2000). Would you use something like AIC as an alternative? – jjulip Oct 1 '14 at 15:11
• Having had a look at RLRsim am I correct in thinking that it still uses LRTs in the way described above but just bootstraps the models first? – jjulip Oct 1 '14 at 15:29
• Yes, but actually "just bootstrapping the model first" is an important caveat. Apologies for being misleading most of my comment regarded selection $X$ not $Z$. In that case $y_{new}$ is the same. Check the relevant section on glmm.wikidot on whether a random effect is significant. I would be extremely cautious to start model-selection on $Z$; I prefer to "treat it as given" based on my research question. Otherwise I simply cherry-pick my error structure. – usεr11852 Oct 1 '14 at 18:48

## 2 Answers

You can report that equation as stated, and add that the coefficient of dd varies from individual to individual with a standard deviation of .215. And also that the individuals' intercepts vary with an SD of .523, and that the SD of error not accounted for by individuals is 2.613. This information is in the summary table of random effects.

On first instance I would suggest you go ahead and use matrix notation directly; by that I mean presenting your equation in a form: \begin{align}\hat{y} = X\hat{\beta} + Z\hat{\gamma} \end{align}

You can then explain that $\hat{\gamma}$ is the estimated realization of the random effects and have the subcomponents of $\hat{\gamma}$, $\hat{\gamma}_{dd}$ and $\hat{\gamma}_{fInd}$ being listed individually. One will immediately see what you estimated. If these vectors are not short ($>9$) I tend to put them in the Appendix.

Having said that as @rvl suggests (+1) it is very helpful to list your the variation due to your random effects as well as the one that is unaccounted for. Regarding that I tend to bootstrap my model so I can report an $\alpha$% conf. interval for that variation; I believe it is more informative in that way and you show your reader that you did a minimum "due diligence" to assure yourself and them that the reported variates are not just manifestations of this particular sample.

Finally: visualize. I do not know if that is possible for your problem but no equation emphasizes the need for a random model better than a graph showing that the marginal model over- or under-estimates certain trends in your data. You can definitely refer to that graph in your methodology section despite being part of your "results" essentially. It does not need to be overly fancy or colorful, just drive home the fact that you obviously have individual specific effects that are uncorrelated with your independent variables in $X$.

• Can I ask what functions you use to bootstrap your model or do you use your own bootstrap implementations? – jjulip Oct 1 '14 at 15:57
• I have used my own as well as bootMer provided by lme4. – usεr11852 Oct 1 '14 at 18:37