Section 5.6 Running a T.Test
In Subsection 4.5.2, we learned how to run a t.test to better understand the difference in means between two groups. If we try to run a t.test on our data now...
# Last chapter we learned how to run a t.test. Let's try it out now.
try(t.test(score ~ method, data = memory))
Error in t.test.formula(formula, data = data, ...) : grouping factor must have exactly 2 levels
It does not work! The reason being is that while t.test compare means, they are only able to calculate the difference between two means. When there are more than two, t.tests fail. We must instead conduct an ANOVA.
