Side by side box plot

basic<-c(21,
         20,
         25,
         22,
         21,
         22,
         22,
         24,
         24,
         23,
         21,
         25,
         23,
         24,
         24)

Conehead<-c(28,
28,
25,
29,
29,
27,
30,
29,
29,
29,
30,
26,
26,
26,
28)

Buckethead<-c(23,
              23,
              23,
              21,
              21,
              22,
              20,
              22,
              22,
              22,
              19,
              19,
              21,
              18,
              18)

dat<-data.frame(basic,Conehead,Buckethead)

boxplot(basic,Conehead,Buckethead)

1 = Basic

2 = Conehead

3 = Buckethead

From the Box Plot we can see that “Basic”, “Conehead” and “Buckethead” appears to have equal variance.

\[ H_0: \mu_1=\mu_2=\mu_3 \]

H_a = at least one mean is different.

library(tidyr)
dat2<-pivot_longer(dat,c(basic,Conehead,Buckethead))
aov.model<-aov(value~name,data=dat2)
summary(aov.model)
##             Df Sum Sq Mean Sq F value   Pr(>F)    
## name         2  396.4  198.20    73.8 1.79e-14 ***
## Residuals   42  112.8    2.69                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Since P-value is 1.79e-14, we reject \(H_0\)

plot(aov.model)

As we can see, the variances between Basic, Buckethead and Conehead shows signs of equality between each other and constant.

When analyzing normality, the QQ plot shows that the data looks fairly normal distributed.

TukeyHSD(aov.model,conf.level=0.05)
##   Tukey multiple comparisons of means
##     5% family-wise confidence level
## 
## Fit: aov(formula = value ~ name, data = dat2)
## 
## $name
##                     diff       lwr       upr     p adj
## Buckethead-basic    -1.8 -1.982656 -1.617344 0.0120723
## Conehead-basic       5.2  5.017344  5.382656 0.0000000
## Conehead-Buckethead  7.0  6.817344  7.182656 0.0000000

From the Tukey’s test, we can see that the pair Buckethead-basic shows a greater sign of difference between their means.