TukeyHSD with ezANOVA output?

1,465 views
Skip to first unread message

Tom Houpt

unread,
Aug 14, 2012, 11:13:24 AM8/14/12
to ez...@googlegroups.com
I'm a newcomer to both R and ez, so this may be an "asked and answered" question.

I would like to run Tukey HSD posthocs after a 2-way mixed within-and-between-Ss design ANOVA (the "standard" posthoc test for my field). But I can't figure out what result from ezANOVA() to pass to TukeyHSD(). 

For example:

> my_anova = ezANOVA(data = TQ, dv = .(Preference), wid = .(Subject), within = .(ExtinctionDay), between = .(Group), type = 3, return_aov=TRUE) 

Warning: Data is unbalanced (unequal N per group). Make sure you specified a well-considered value for the type argument to ezANOVA(). 
 
> TukeyHSD(my_anova)
 
  no applicable method for 'TukeyHSD' applied to an object of class "list"
Error in UseMethod("TukeyHSD") : 

(Data from a conditioned taste aversion learning experiment: Preference scores measured between Groups of Subjects but across repeated days of Extinction testing.)

Should I be passing a subelement of the my_anova list to TukeyHSD? Or is the application of TukeyHSD incompatible with 2-way mixed ezANOVA output?

Thanks in advance for any pointers.

Tom

Mike Lawrence

unread,
Aug 15, 2012, 7:03:18 AM8/15/12
to ez...@googlegroups.com
I believe that you want to do:

TukeyHSD(my_anova$aov)

sviter

unread,
Dec 17, 2012, 7:48:54 AM12/17/12
to ez...@googlegroups.com
 TukeyHSD(my_anova$aov)  return error:

Error in UseMethod("TukeyHSD") :
no applicable method for 'TukeyHSD' applied to an object of class "c('aovlist', 'listof')"

среда, 15 августа 2012 г., 14:03:18 UTC+3 пользователь Mike Lawrence написал:
Reply all
Reply to author
Forward
0 new messages