Hello guys,

I have a somewhat R and biostats question. I want to make boxplots with ggplot2 package and include in them the significance bars between groups. I have 4 groups in the boxplots. In my short statistic classes I always learned that I should do a OneWay ANOVA and then use multiple comparison tests (like Tukey HSD). However, in this package I can only use "t-test" or "wilcox.test" and I also learned that repeating t-tests in the same group of comparisons increases some kind of error.

Therefore, my question to you is if I can use the t-test to make the multiple comparisons between subgroups, or if I should perform ANOVA and the Tukey HSD for the multiple comparisons. If you think I should go for the Tukey, can you explain why the package only includes the T-test?

I appreciate any help you can give!

Cheers!

It seems to me that anova followed by HSD is a more sensible approach than applying independent t-tests. Granted this is the first time I see the ggsignif package, I'm kind of surprised it doesn't provide an out-of-the-box mechanism to implement multiple testing corrections. However, I see that the

`test`

parameter of geom_signif accepts a custom function name (If you implement a custom test make sure that it returns a list that has an entry called p.value), so you could write your own method.Hello Dariober, That seems like a good solution, however I'm pretty new to R. Could you tell me how I can do that?