library(dplyr)
library(tidyr)
library(GAD)
Machine <- c(rep(1,8),rep(2,8),rep(3,8))
Spindle <- rep(c(rep(1,4),rep(2,4)),3)
Obs <- c(12,9,11,12,8,9,10,8,
14,15,13,14,12,10,11,13,
14,10,12,11,16,15,15,14)
dat14.3 <- data.frame(Machine,Spindle,Obs)
Machine <- as.fixed(Machine)
Spindle <- as.random(Spindle)
model14.3 <- lm(Obs~Machine+Spindle%in%Machine)
gad(model14.3)
## Analysis of Variance Table
##
## Response: Obs
## Df Sum Sq Mean Sq F value Pr(>F)
## Machine 2 55.75 27.8750 1.9114 0.2915630
## Machine:Spindle 3 43.75 14.5833 9.9057 0.0004428 ***
## Residual 18 26.50 1.4722
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
GAD results with the nested Spindle factor having a p-value of 0.0004 and the Machine factor having a p-value of 0.2916. Assuming \(\alpha=0.05\), the Spindle has a significant effect on dimensional variability and the Machine does not.