TukeyHSD(a2, "ses") Tukey multiple comparisons of means The TukeyHSD command still works well, though now we must We can look at pair-wise comparisons of the ses levels after adjustingįor female. You may be fitting an ANOVA with multiple factors. We can see that these results are significant with what we saw using otherĪdjustments for the p-values. Now I use Benjamini-Hochberg procedure to calculate adjusted p-values in R: p.adjust (pvalues, method'BH') (I can use Benjamini and Yekutieli instead for dependence, but lets skip this for now) As far as I understand, this gives me a set of q-values, that is. Below, we show code for using the TukeyHSD (Tukey Honest Significant Differences). In total, I can calculate 5 pairwise comparisons > 120 p-values. The pairwise.t.test command does not offer Tukey post-hoc tests, but there are other R commands that allow for Tukey comparisons. We can see that the adjustments all lead to increased p-values, but consistently the high-low and high-middle pairs appear to be significantly different at alpha =. Pairwise.t.test(write, ses, p.adj = "holm") pairwise.t.test(write, ses, p.adj = "bonf") Below we show Bonferroni and Holm adjustments to the p-valuesĪnd others are detailed in the command help. With this same command, we can adjust the p-values according to a variety of methods. Pairwise comparisons using t tests with pooled SD Pairwise.t.test command and indicating no adjustment of p-values: pairwise.t.test(write, ses, p.adj = "none") For an one-way ANOVA (ANOVA with a single factor) We can first see the unadjusted p-values using the We consider to be statistically significant to account for this multiplicity of Of freedom test, but we do not know which pairs of ses levels are We will be using the hsb2 dataset and looking at the Options for adjusting the p-values of these comparisons given the number of We will demonstrate the how to conduct pairwise comparisons in R and the different Example is shown below in the How to do the tests section. You may know that the means of your response variable differ significantlyĪcross your factor, but you do not know which pairs of the factor levels are Controlling the familywise error rate: Bonferroni correction. Have been found when there are three or more levels of a factor. Post-hoc pairwise comparisons are commonly performed after significant effects
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |