ChiLiubio / microeco

An R package for data analysis in microbial community ecology
GNU General Public License v3.0
195 stars 56 forks source link

An Error in trans_env$cal_diff (), method = "KW_dunn" #261

Closed sdhorse closed 6 months ago

sdhorse commented 1 year ago

Dear, Dr. Liu When I choose non-parametric tests for multiple comparisons, i.e. method = "KW_dunn": t1$cal_diff(method = "KW_dunn", group = "Group", p_adjust_method = "none") After plotting by t1$plot_diff (), it was found that the difference letters are sometimes denoted by “a” for larger values and sometimes by “b” for larger values (see attached figure). In addition, the t1$res_diff () run results in an alphabetical order in the “Group” column, not in a customized order. 微信截图_20230720110038

ChiLiubio commented 1 year ago

Hi. Yes. I find it! The issue comes from unordered comparison groups of dependent dunnTest function of FSA package. I have fixed it in the updated github package by adding a checking step. Now the groups are ordered by the median values from high to low. Please reinstall the package from the github and try again. Thanks for your finding!

Best Chi