# Mixed and Multilevel Models

Jump to navigation
Jump to search

## Contents

## General

- Mixed models are one of the trickiest tools to understanding what is going on at the macro and micro level.
- Level 1 is the observation, and level 2 is the cluster.
- Observations are not independent, but rather observations are correlated
- Two general types:
- Cross-sectional data where individuals are nested within geographical or social context
- Longitudinal data which deal with repeat measurements across individuals

- Examples
- Class, School, district clustering in educational attainment
- Relationships at different levels may not be equivalent: States with higher incomes tend to vote Democratic, but within states richer individuals tend to support republican rather than democratic.

- "Estimated standard errors for fixed effects are greater under multilevel generalized linear modeling, which is not unusual after accounting for correlated observations, which effectively reduces the sample size."
- G-matrix

### Procedure

- Exploratory data analysis - standard univariate and bivariate scatterplot matrices apply. Mixed model specific plots are lattice plots, spaghetti plots.
- Decide which variable are fixed effect versus random effect
- Unconditional means model - ..."no predictors at any level. The purpose of the unconditional means model is to assess the amount of variation at each level, and to compare variability within school to variability between schools."
- Unconditional Growth Model

## References

- 2019 Sun et al - Statistical inference for time course RNA-Seq data using a negative binomial mixed-effect model
- Roback and Legler 2020 - "Beyond Multiple Linear Regression: Applied Generalized Linear Models and Multilevel Models in R"
- Shrinkage in Mixed Effects Models Good demonstrations of making fake random effects data and backing out parameters using lme4]
- Mixed Model Guide (Tufts U.)
- Ben Bolker glmm FAQ
- Multilevel models for longitudinal data - Fiona Steele 2007
- U. Bristol Centre for Miltilevel Modelling

## Journal Club

### Bell et al 2019

- Bell et al 2019 Fixed and random effects models: making an informed choice
- "Estimated effect standard errors are UNDERestimated when random-slope variation exist but a model does not allow for it"
- Robustness of estimation results to mis-specification of random effects as normally distributed when they are not.
- "... level-2 random effects are treated as random draws from a Normal distribution."
- "treating higher level entities as distinct but not completely unlike each other"
- "the random intercepts in RE models will correlate strongly with the fixed effects in a ‘dummy variable’ FE models, but RE estimates will be drawn in or ‘shrunk’ towards their mean—with unreliably estimated and more extreme values shrunk the most."
- "RE gives appropriately conservative estimates of differences in level 2 entities"

## Packages

### LME4

### MCMCglmm

- Hadfield 2010 paper
- Jarrod Hadfield course notes
- Using MCMCglmm to implement lme4-like Bayesian mixed-effects models - Tutorial
- Owls worked example using MCMCglmm

### glmmLasso

- Groll et al 2014 paper - Variable selection for generalized linear mixed models by L1-penalized estimation
- Schelldorfer et al 2012 - GLMMLasso: An Algorithm for High-Dimensional Generalized Linear Mixed Models Using L1Penalization