tidy_stats.afex_aov: Create a tidy stats data frame from an afex aov object

Description Usage Arguments Examples

View source: R/tidy_stats.afex_aov.r

Description

tidy_stats.aov takes an afex aov object and converts the object to a tidy stats data frame.

Usage

1
2
## S3 method for class 'afex_aov'
tidy_stats(model, args = NULL)

Arguments

model

Output of afex's aov_ez, aov_car, or aov_4

args

Unused

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
# Check if afex package is available
if(!requireNamespace("afex", quietly = TRUE)) {

  message(paste0("Package 'afex' is needed for this example to work. ",
              "Please install it."), .call = FALSE) 
} else {

  # Load data
  data(obk.long, package = "afex")

  # Conduct an ANOVA
  afex_aov <- afex::aov_4(value ~ treatment * gender + (phase * hour | id),
                          data = obk.long, observed = "gender")

  # Tidy stats
  tidy_stats(afex_aov)
}

WillemSleegers/tidystats-v0.3 documentation built on Aug. 12, 2019, 5:31 p.m.