testResiduals: Residual's formal tests for ANOVA models

View source: R/biblioteca.R

testResidualsR Documentation

Residual's formal tests for ANOVA models

Description

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

Usage

testResiduals(
  model,
  normality.test = c("sw", "ad"),
  var.test = c("bartlett", "levene")
)

Arguments

model

an object of the class lm or aov.

normality.test

type of normality test; currently Shapiro-Wilk (SW) and Anderson-Darling (AD) tests are available

var.test

type of homogeneity test of variances; currently Bartlett and Levene tests are available

Value

residuals' normality test and residuals' homoneity test of variances.

Examples

library(planex)
library(tidyverse)
baterias <- mutate(baterias,
  temperatura = as.factor(temperatura),
  tipo = as.factor(tipo)
)

mod <- aov(tempo ~ temperatura*tipo, data=baterias)
testResiduals(mod)


fndemarqui/planex documentation built on July 9, 2024, 2:13 a.m.