Kruskal-Wallis test with details on pairwise comparisons

后端 未结 4 944
日久生厌
日久生厌 2020-12-12 23:11

The standard stats::kruskal.test module allows to calculate the kruskal-wallis test on a dataset:

>>> data(diamonds)
>>> kruskal.test(price         


        
4条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-12 23:48

    I would have thought you'd be able to do the following:

    data(diamonds, package = "ggplot2")
    
    library(coin)
    library(multcomp)
    
    kt <- kruskal_test(price ~ clarity, data = diamonds)
    glht(kt, mcp(clarity = "Tukey"))
    

    But it seems like multcomp doesn't support coin objects (yet?).

提交回复
热议问题