tadaa_aov

0th

Percentile

Tadaa, ANOVA!

Performs one-, two-way or factorial ANOVA with adjustable sums of squares method and optionally displays effect sizes ((partial) \(\eta^2\), Cohen's f) and power (calculated via pwr::pwr.f2.test to work with unbalanced designs).

Usage
tadaa_aov(formula, data = NULL, show_effect_size = TRUE,
  show_power = TRUE, factorize = TRUE, type = 3, check_contrasts = TRUE,
  print = c("df", "console", "html", "markdown"))
Arguments
formula

Formula for model, passed to aov.

data

Data for model.

show_effect_size

If TRUE (default), effect sizes partial eta^2 and Cohen's f are appended as columns.

show_power

(Experimental) If TRUE (default), power is calculated via pwr::pwr.f2.test and appended as a column.

factorize

If TRUE (default), non-factor independent variables will automatically converted via as.factor, so beware of your inputs.

type

Which type of SS to use. Default is 3, can also be 1 or 2.

check_contrasts

Only applies to type = 3. If TRUE (default), the contrasts of each non-ordered factor are set to "contr.sum".

print

Print method, default df: A regular data.frame. Otherwise passed to pixiedust::sprinkle_print_method for fancyness.

Details

If a specified independent variable is not properly encoded as a factor, it is automatically converted if factorize = TRUE to ensure valid results.

If type = 3 and check_contrasts = TRUE, the "contrasts" of each non-ordered factor will be checked and set to contr.sum to ensure the function yields usable results. It is highly recommended to only use check_contrasts = FALSE for debugging or educational purposes, or of you know what you're doing and using your own contrast matrix.

Value

A data.frame by default, otherwise dust object, depending on print.

See Also

Other Tadaa-functions: tadaa_chisq, tadaa_kruskal, tadaa_levene, tadaa_nom, tadaa_normtest, tadaa_one_sample, tadaa_ord, tadaa_pairwise_gh, tadaa_pairwise_tukey, tadaa_pairwise_t, tadaa_t.test, tadaa_wilcoxon

Aliases
  • tadaa_aov
Examples
# NOT RUN {
tadaa_aov(stunzahl ~ jahrgang, data = ngo)
tadaa_aov(stunzahl ~ jahrgang * geschl, data = ngo)

# Other types of sums and print options
# }
# NOT RUN {
tadaa_aov(stunzahl ~ jahrgang * geschl, data = ngo, type = 1, print = "console")
tadaa_aov(stunzahl ~ jahrgang * geschl, data = ngo, type = 3, print = "console")
tadaa_aov(stunzahl ~ jahrgang * geschl, data = ngo,
          type = 3, check_contrasts = FALSE, print = "console")
# }
Documentation reproduced from package tadaatoolbox, version 0.16.0, License: MIT + file LICENSE

Community examples

Looks like there are no examples yet.