1-Way ANOVA- Model Representations, Power, and Sample Size Tutorial
2020-12-28
Part 1 Introduction
ANOVA is short for analysis of variance. It is a widely used statistical method used with designed experiments. Given its frequency of use, it is my opinion that anyone interested in academic research understand the basics. . . even if you never use it in your own research, I guarantee you will encounter it somewhere in the literature! Briefly, ANOVA is an “accounting” procedure that keeps track of all the variation in a response variable. ANOVA partitions this variation into pieces and uses these pieces to assess the likelihood that differences found between means in sample data could be the result of random chance.
This tutorial focuses on 1-way ANOVA, specifically ways to model our data in the context of this statistical method. We introduce the means and effects models and their assumptions and implement these approaches manually in R. We also discuss power and sample size and provide an interactive visualization to see what influences power in an ANOVA. Discussion of power and sample size helps answer the question: “How might we increase the chances of getting a statistically significant result from our ANOVA?” Thinking about power and sample size not only will bolster your statistical chops, it might also come in handy in practice when planning research design or writing research grant proposals.
The tutorial assumes you have used R before and are familiar working with matrices. Some examples and demos utilize functions from the Tidyverse (Wickham 2019). This tutorial was written using the bookdown package (Xie 2020), which was built on top of R Markdown and knitr (Xie 2015).
References
Wickham, Hadley. 2019. Tidyverse: Easily Install and Load the ’Tidyverse’. https://CRAN.R-project.org/package=tidyverse.
Xie, Yihui. 2015. Dynamic Documents with R and Knitr. 2nd ed. Boca Raton, Florida: Chapman; Hall/CRC. http://yihui.org/knitr/.
Xie, Yihui. 2020. Bookdown: Authoring Books and Technical Documents with R Markdown. https://CRAN.R-project.org/package=bookdown.