t6q2 <- read.table("C:/Users/Wei Hao/Desktop/ST2137/Tutorials/Data/wip.txt", header=TRUE)
attach(t6q2)
gp.a <- time[plant==1]
gp.b <- time[plant==2]
wilcox.test(gp.a,gp.b)
## Warning in wilcox.test.default(gp.a, gp.b): cannot compute exact p-value
## with ties
##
## Wilcoxon rank sum test with continuity correction
##
## data: gp.a and gp.b
## W = 135.5, p-value = 0.0834
## alternative hypothesis: true location shift is not equal to 0
We are testing \(H_0 : \mu_1 - \mu_2 = 0\) against \(H_1: \mu_1 - \mu_2 \neq 0\). From the Wilcoxon rank sum test, we have p-value \(=0.0822\). Thus, we do not reject \(H_0\).