0
$\begingroup$

I'm trying to do a two way ANOVA on a dataset with 2 fixed effects factors (Genotype and Treatment). However, depending on the order of which the factors are in the model formula, I'm getting different results. Results

Formulas are : aov(Angle~GenotypeTreatment) for "modele2" and aov(Angle~TreatmentGenotype) for "modele21".

Can you guys help me figuring out why this happens ?

$\endgroup$
3
  • $\begingroup$ I'm not sure it actually answers my question as he uses a mixed effects model, my effects are fixed. I looked on other statistics website and found that i should use type III ANOVA, but i'm not sure I understand why $\endgroup$
    – legabogb
    Commented Oct 26, 2023 at 9:16
  • $\begingroup$ There are no mixed models at the linked thread, and it explains what the difference between the three types is. If you clarify what is unclear by editing your question, someone here might be able to explain it. $\endgroup$
    – mkt
    Commented Oct 26, 2023 at 9:20
  • $\begingroup$ You might also look at this question, which shows that you can have the same problem in a fixed-effects model even without an interaction, and this answer, which (1) explains how order dependence in the default R "Type I" anova() or aov() is to be expected in unbalanced designs and (2) provides a link to a discussion of different ANOVA types in the help page to the Anova() function (capital "A") in the R car package. $\endgroup$
    – EdM
    Commented Oct 26, 2023 at 14:11

0

Browse other questions tagged or ask your own question.