I am getting different results depending on whether I run ezANOVA or stats aov. From looking for comments on that, my sense is that should not happen. So I assume I am doing something in the code, but I can't figure it out:
> ezANOVA (
+ data = NAT_St,
+ dv = ACC,
+ wid = .(SubjectID),
+ within = .(WOC, Length),
+ return_aov = F
+ )
Warning: Converting "SubjectID" to factor for ANOVA.
$ANOVA
Effect DFn DFd F p p<.05 ges
2 WOC 1 97 84.651636 7.139493e-15 * 0.119711847
3 Length 1 97 45.990808 9.352443e-10 * 0.042665044
4 WOC:Length 1 97 9.177398 3.140336e-03 * 0.009169768
>
>
> fit <- aov(ACC ~ WOC*Length + Error(SubjectID/(WOC*Length)), data = NAT_St)
> summary (fit)
Error: SubjectID
Df Sum Sq Mean Sq F value Pr(>F)
Residuals 1 0.1364 0.1364
Error: SubjectID:WOC
Df Sum Sq Mean Sq
WOC 1 5.059 5.059
Error: SubjectID:Length
Df Sum Sq Mean Sq
Length 1 2.251 2.251
Error: SubjectID:WOC:Length
Df Sum Sq Mean Sq
WOC:Length 1 0.5691 0.5691
Error: Within
Df Sum Sq Mean Sq F value Pr(>F)
WOC 1 2.71 2.7145 18.347 2.33e-05 ***
Length 1 0.42 0.4248 2.871 0.091 .
WOC:Length 1 0.04 0.0401 0.271 0.603
Residuals 384 56.81 0.1480
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1