Dear r-helpers, I want to test groups of samples for significant differences. Question: Does Group1 differ significantly from group2. This is a question to be answered by mann-whitney-u-test.
I know that I can use wilcox.test with 2 samples. My problem: How can r perform the test automatically if there are more than 2 groups in my data frame. Test group1 vs. 2, 1 vs. 3, 1 vs. 4, etc. This is my skript: Deckung <- read.table("Gesamtdeckung.csv", sep=";", header=TRUE, dec=",", row.names=1) x <- Deckung$Gesamtdeckung y <- Deckung$Klasse #U-Test wilcox.test(x ~ y, paired = FALSE, subset = y %in% c("1", "2")) wilcox.test(x ~ y, paired = FALSE, subset = y %in% c("1", "3")) wilcox.test(x ~ y, paired = FALSE, subset = y %in% c("2", "3")) Any help would be greatly appreciated! Thanks Kim -- GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT! ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.