This function is only suitable to analyze residuals of ANOVA models. It must not be used to analyze residuals from regression or ANCOVA models.

ggresiduals(object)

Arguments

model

an object of the class lm or aov.

Value

residual plots suitable for residual analysis of data from design experiments.

Examples

library(planex)
library(tidyverse)
data(saquinhos)
saquinhos <- mutate(saquinhos,
  concentracao = as.factor(concentracao)
)
mod <- aov(resistencia ~ concentracao, data = saquinhos)
ggresiduals(mod)
#> Warning: The `augment()` method for objects of class `aov` is not maintained by the broom team, and is only supported through the `lm` tidier method. Please be cautious in interpreting and reporting broom output.
#> 
#> This warning is displayed once per session.


#> `geom_smooth()` using method = 'loess' and formula = 'y ~ x'
#> Warning: pseudoinverse used at 9.9442
#> Warning: neighborhood radius 7.0558
#> Warning: reciprocal condition number  7.1324e-17
#> Warning: There are other near singularities as well. 30.867