Learn R Programming

sjmisc (version 1.0.2)

eta_sq: Compute eta-squared of fitted anova

Description

Returns the eta-squared value for one-way-anovas.

Usage

eta_sq(...)

Arguments

...
A fitted one-way-anova model or a dependent and grouping variable (see examples).

Value

  • The eta-squared value.

References

  • http://stats.stackexchange.com/questions/78808/{How to compute eta-sq in ANOVA by hand?}
  • http://stats.stackexchange.com/questions/15958/{How to interpret and report eta squared?}
  • http://en.wikiversity.org/wiki/Eta-squared{Wikipedia: Eta-squared}
  • Levine TR, Hullett CR (2002): Eta Squared, Partial Eta Squared, and Misreporting of Effect Size in Communication Research (https://www.msu.edu/~levinet/eta%20squared%20hcr.pdf{pdf})

Examples

Run this code
# load sample data
data(efc)

# fit linear model
fit <- aov(c12hour ~ as.factor(e42dep), data = efc)

# print eta sqaured
eta_sq(fit)

# grouping variable will be converted to factor autoamtically
eta_sq(efc$c12hour, efc$e42dep)

Run the code above in your browser using DataLab