R+scripts+Unit+4-+commercialisation

=Click to Go back to main page=

Fried man 4 colour

> colour<- matrix(c(7,7,7,9,7,7,7,4,6,7,8,6,4,4,5,6,7,7,6,9,7,4,8,6,8,6,8,8,8,9,7,8, + 7,7,7,8,7,8,6,7,4,7,8,4,4,8,6,9,6,9,7,8,7,6,8,5,8,7,8,9,7,6,7,7, + 6,6,6,4,2,7,4,1,8,7,9,5,3,5,5,5,6,8,6,7,8,5,9,4,6,3,3,2,4,7,5,7, + 7,7,8,2,2,7,4,3,7,7,8,6,6,7,4,6,7,6,7,4,5,6,3,6,8,5,1,1,5,3,7,5), + nrow = 32,byrow = FALSE, + dimnames = list(1 : 32, c("our1", "our2", "comm","tea"))) > result <-friedman.test(colour) > result

Friedman rank sum test

data: colour Friedman chi-squared = 16.1418, df = 3, p-value = 0.001061

> Ranktotals <- c(abs(colSums(colour)1-colSums(colour)2), + abs(colSums(colour)1-colSums(colour)3), + abs(colSums(colour)1-colSums(colour)4), + abs(colSums(colour)2-colSums(colour)3), + abs(colSums(colour)2-colSums(colour)4), + abs(colSums(colour)3-colSums(colour)4), + qtukey(0.95,4,999)*sqrt((32*4*(4+1))/12)) > Comparisons <- c("our1-our2","our1-comm","our1-tea","our2-comm","our2-tea", + "comm-tea","critical distance for HSDRanks") > HSDRank.comparisons <- data.frame(Ranktotals, row.names=Comparisons) > HSDRank.comparisons Ranktotals our1-our2 5.00000 our1-comm 44.00000 our1-tea 47.00000 our2-comm 49.00000 our2-tea 52.00000 comm-tea 3.00000 critical distance for HSDRanks 26.57755 > =Click to Go back to main page=