0

I am trying to find a non-parametric two-way ANOVA test. My data can not be normalized I have tried everything.

Many people say that Kruskal-Wallis is equivalent to a two-way ANOVA, except when I code it in R nothing works.

kruskal.test(Variable 1 ~ Variable 2*Variable3, data=data)

I have also tried "+" and ":" instead of "*" and each time I receive: Error in kruskal.test.formula() : 'formula' should be of the form response ~ group.

Is a two-way Kruskal-Wallis test not possible to perform in R?

  • 2
    Does this answer your question? Is there an equivalent to Kruskal Wallis one-way test for a two-way model? In particular, note the suggestion from Frank Harrell to use a proportional-odds ordinal logistic multiple regression as a generalization of K-W. That makes no assumptions about the distribution of residuals. – EdM Mar 10 '22 at 19:17
  • 2
    In roughly the same way as one-way ANOVA with three levels of the factor is a generalization of the pooled 2-sample t test, one can say that a K-W test may be considered as a generalization of the 2-sample Wilcoxon rank sum test. // somewhat similarly, a non-parametric analog of a simple ANOVA block design [that is, a two-factor ANOVA (blocks as the second factor, one replication per cell)] is the Friedman test, but no test is made for blocks. // Be careful about assumptions for such rank-based nonparametric tests. They do not assume normality, but they do make some assumptions. – BruceET Mar 10 '22 at 21:06

0 Answers0