Skip to content

R: RE: R: RE: Bonferroni post hoc test in R for repeated measure ANOVA with mixed within and between subjects design

1 message · angelo.arcadi at virgilio.it

#
Dear Michael,
I am very grateful to you for the detailed explanation, now everything is clear. In the end I will opt for the Tuckey method then.

Thanks

Best

A.




----Messaggio originale----
Da: meyners.m at pg.com
Data: 7-lug-2015 8.58
A: "angelo.arcadi at virgilio.it"<angelo.arcadi at virgilio.it>
Cc: "r-help at r-project.org"<r-help at r-project.org>, "John Fox"<jfox at mcmaster.ca>
Ogg: RE: [R] R: RE: Bonferroni post hoc test in R for repeated measure ANOVA with mixed within and between subjects design

Angelo,

the conservatism of Bonferroni aside for a moment, I don't really see what you are after. 

mcp(Emotion = "Tukey")

just defines the contrasts to test; in this case, all pairwise comparisons. 

The test=adjusted("bonferroni") argument then says that these contrasts should not be corrected for according to Tukey's procedure, but using Bonferroni adjustment. 

So this should give you tests for all pairwise comparisons with multiplicity correction according to Bonferroni. I wonder how this differs from the results you get from SPSS. 

Seemingly, this is not what you want, so the question is what you really want. "Bonferroni method" does not indicate which comparisons / contrasts to look at, but just takes all those that you are interested in and multiply the corresponding p values with the number of comparisons (and making sure it does not exceed 1). As John indicated, that can easily be handled manually. Yet, you need to create the tests for all comparisons that you are interested in - if not via  linfct=mcp(Emotion = "Tukey"), you need to specify them otherwise (see the three options indicated on ?glht). The code I suggested offers a convenient shortcut in case you are interested in all pairwise comparisons and want them to be corrected according to Bonferroni, but if something else is of interest, you'd need to specify this (and let us know, as "Bonferroni method" does not give a clue about which comparisons to test).

NB: You may want to pay attention to the warning halfway down the helppage for ?mcp; it may not be clear exactly which effects you want to compare; mcp uses just the main effects w/o interactions etc.

Michael