Checks a simple, multiple, or mixed-effects linear regression model for normality. The function outputs an orientation plot and computes a relevant statistical test: Shapiro-Wilk test on model residuals.

normality_check(mdl)

Arguments

mdl

A simple, multiple, or mixed-effects linear regression model.

Value

A plot and a test results in the console.

Author

D. Schmitz & J. Esser

Examples

data("data_s")

model <- lm(sDur ~ typeOfS + pauseDur, data_s)

normality_check(model)
#> Error in ggplot(): could not find function "ggplot"