── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
✔ dplyr 1.1.4 ✔ readr 2.1.5
✔ forcats 1.0.0 ✔ stringr 1.5.1
✔ ggplot2 3.5.2 ✔ tibble 3.3.0
✔ lubridate 1.9.4 ✔ tidyr 1.3.1
✔ purrr 1.1.0
── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
✖ dplyr::filter() masks stats::filter()
✖ dplyr::lag() masks stats::lag()
ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
library(janitor)
Attaching package: 'janitor'
The following objects are masked from 'package:stats':
chisq.test, fisher.test
library(readxl)library(car)
Loading required package: carData
Attaching package: 'car'
The following object is masked from 'package:dplyr':
recode
The following object is masked from 'package:purrr':
some
This homework assignment analyzes crayfish growth data from Sargent and Lodge (2014) to examine differences in growth rates between native and invasive populations of rusty crayfish (Orconectes rusticus) using one-way ANOVA.
Learning Objectives
By completing this assignment, you will be able to:
Understand one-way ANOVA concepts and applications
Perform exploratory data analysis for group comparisons
Conduct one-way ANOVA analysis
Test statistical assumptions for ANOVA
Interpret ANOVA results and effect sizes
Create publication-quality figures
Write scientific methods and results sections
Data Description
The dataset contains growth measurements from a common garden experiment where young-of-year (YOY) rusty crayfish from native (Ohio) and invasive (Wisconsin) populations were grown in enclosures in northern Wisconsin lakes during summer 2011.
More conservative than η² because it adjusts for bias in small samples
Why Calculate Both?
Eta-squared (η²): Easier to calculate and interpret, but slightly overestimates effect size
Omega-squared (ω²): More accurate, unbiased estimate of population effect size
Effect Size Interpretation Guidelines:
Effect Size η² / ω² Interpretation
Small 0.01 1% of variance explained
Medium 0.06 6% of variance explained
Large 0.14 14% of variance explained
Example Output Interpretation:
If your results show:
eta_squared omega_squared
1 0.21 0.20
This means:
21% of the variance in crayfish growth rate is explained by population range (η²)
20% is the unbiased estimate of variance explained (ω²)
This represents a large effect size (much larger than 0.14)
Population range is a strong predictor of growth rate
Bottom line: Both metrics tell you how much of the differences in crayfish growth can be attributed to whether they’re from native vs. invasive populations, with omega-squared being the more conservative (and accurate) estimate.
# levene_test_result <- leveneTest(response ~ factor, data = cradfy_df)# levene_test_result
Part 6: Publication Figure
6.1 Create Publication-Quality Figure
Submission Guidelines
What to turn in -
a quarto markdown file and dataframe if you modified the original. All of the code should be able to run with what you turn in. (2 points)
a self-contained html file showing the code and output (2 points)
annotations in the quarto file that shows or tells what is being done in the r code chunks describing what you are trying to do - credit will be given even if it does not work as long as you detail what you are doing. As we start to move into more statistics you will be expected to interpret the results. (2 points)