6.7 Chapter summary
You can use Generalized Linear Models when the outcome variable is not continuous. Models of the binomial family are suitable where the outcome is an event that either happens or not. You fit Generalized Linear Models with R function glm()
. Linear Mixed models are for cases where there is clustering in the data, for example due to several responses coming from each participant. Linear Mixed Models can be fitted using contributed packages lme4
and lmerTest
. The syntax for specifying Generalized Linear Models and Linear Mixed Models is similar to that for General Linear Models with a few small additions.