Multcompare function for post-hoc test in 2-way repeated measures ANOVA
38 ビュー (過去 30 日間)
古いコメントを表示
Hello, I would like to ask about the correctness of the results of multcompare function for 2-way repeated measures ANOVA.
I performed 2 way repeated measures ANOVA and used function multcompare for post-hoc tests in MATLAB (by default it uses 'ComparisonType', 'Tukey-Kramer'). I also performed the same analysis in the program STATISTICA (from TIBCO) using post-hoc Tukey HSD, which should be the same as the default in mulcompare. I've got the same F-statistic and p-values in ANOVA results in both programs, but very different outputs of post-hoc Tukey tests.
Here is the part of the code I used in MATLAB (two within-subject factors: Time and Condition).
% specify that all variables are in the same group - repeated measures
repeatFactors = table(factor1,factor2, 'VariableNames',{'Conditions' 'Time'});
% create a model to be fit with repeated measures
rm = fitrm(data,'control_0_2-allo_1_0 ~ 1','WithinDesign',repeatFactors);
% fit the model
ranova_table = ranova(rm,'WithinModel','Conditions*Time');
% multiple comparisons across groups
Tukey_table = multcompare(rm,'Conditions', 'By', 'Time');
So, I wonder what the reason could be for the different post-hoc results and if I'm using the function multcompare correctly with 2-way repeated measures ANOVA.
Thanks!
1 件のコメント
Scott MacKenzie
2021 年 7 月 28 日
I would help if you post the data -- so the issues with your question can be explored by executing your code.
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Analysis of Variance and Covariance についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!