GLMMs
Generalized linear mixed models (GLMMs) extend generalized linear models by incorporating random effects to account for correlation within clusters and hierarchical data, while allowing non-normal response distributions. In a GLMM, the outcome y_ij follows a distribution from the exponential family with mean μ_ij, and a link function g relates μ_ij to a linear predictor: g(μ_ij) = X_ijβ + Z_ijb_i. Here β are fixed-effect coefficients, b_i are random effects associated with group i, and b_i is typically assumed multivariate normal with mean 0 and covariance D. The design matrices X_ij and Z_ij connect observations to fixed and random components, respectively. This structure enables population-level inferences while modeling within-group correlation and extra variation via the random effects.
Estimation involves integrating over the random effects to obtain a marginal likelihood, which is usually not
GLMMs support a range of designs, including nested and crossed random effects, and can handle various outcomes