The yield of a chemical process was measured using five batches of raw material, five acid concentrations, five catalyst concentrations (A, B, C, D, E), and five standing times (𝛼, 𝛽, 𝛾, 𝛿, 𝜖). The Graeco-Latin square that as in table below. Analyze the data from this experiment (use 𝛼 = 0.05) and draw conclusions.
#import data
library(readr)
data <- read_csv("/Volumes/GoogleDrive/My Drive/NORATIKAH/EDA/coding/Exercise 3.5.csv")
── Column specification ────────────────────────────────────────────────────────────────────────────────────────────────────────────────
cols(
Batch = col_double(),
Acid = col_double(),
Times = col_character(),
Catalyst = col_character(),
Time = col_double()
)
data
Treatment1 = as.factor(data$Catalyst)
Row = as.factor(data$Batch)
Column = as.factor(data$Acid)
Treatment2 = as.factor(data$Times)
results = aov(Time~Row+Column+Treatment1+Treatment2,data)
summary(results)
Df Sum Sq Mean Sq F value Pr(>F)
Row 4 10.0 2.50 0.427 0.785447
Column 4 24.4 6.10 1.043 0.442543
Treatment1 4 342.8 85.70 14.650 0.000941 ***
Treatment2 4 12.0 3.00 0.513 0.728900
Residuals 8 46.8 5.85
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
TukeyHSD(results)
Tukey multiple comparisons of means
95% family-wise confidence level
Fit: aov(formula = Time ~ Row + Column + Treatment1 + Treatment2, data = data)
$Row
diff lwr upr p adj
2-1 -0.2 -5.484751 5.084751 0.9999182
3-1 -0.8 -6.084751 4.484751 0.9823986
4-1 -1.4 -6.684751 3.884751 0.8834072
5-1 -1.6 -6.884751 3.684751 0.8279246
3-2 -0.6 -5.884751 4.684751 0.9939694
4-2 -1.2 -6.484751 4.084751 0.9281909
5-2 -1.4 -6.684751 3.884751 0.8834072
4-3 -0.6 -5.884751 4.684751 0.9939694
5-3 -0.8 -6.084751 4.484751 0.9823986
5-4 -0.2 -5.484751 5.084751 0.9999182
$Column
diff lwr upr p adj
2-1 -0.2 -5.484751 5.084751 0.9999182
3-1 0.6 -4.684751 5.884751 0.9939694
4-1 -1.2 -6.484751 4.084751 0.9281909
5-1 -2.2 -7.484751 3.084751 0.6232282
3-2 0.8 -4.484751 6.084751 0.9823986
4-2 -1.0 -6.284751 4.284751 0.9610846
5-2 -2.0 -7.284751 3.284751 0.6948188
4-3 -1.8 -7.084751 3.484751 0.7640759
5-3 -2.8 -8.084751 2.484751 0.4197369
5-4 -1.0 -6.284751 4.284751 0.9610846
$Treatment1
diff lwr upr p adj
B-A -8.0 -13.284751 -2.7152488 0.0051639
C-A -4.8 -10.084751 0.4847512 0.0770797
D-A -8.6 -13.884751 -3.3152488 0.0032815
E-A -10.6 -15.884751 -5.3152488 0.0008219
C-B 3.2 -2.084751 8.4847512 0.3087034
D-B -0.6 -5.884751 4.6847512 0.9939694
E-B -2.6 -7.884751 2.6847512 0.4837165
D-C -3.8 -9.084751 1.4847512 0.1869031
E-C -5.8 -11.084751 -0.5152488 0.0317351
E-D -2.0 -7.284751 3.2847512 0.6948188
$Treatment2
diff lwr upr p adj
Beta-Alpha 0.4 -4.884751 5.684751 0.9987373
Delta-Alpha -0.2 -5.484751 5.084751 0.9999182
Eta-Alpha 1.2 -4.084751 6.484751 0.9281909
Gamma-Alpha 1.6 -3.684751 6.884751 0.8279246
Delta-Beta -0.6 -5.884751 4.684751 0.9939694
Eta-Beta 0.8 -4.484751 6.084751 0.9823986
Gamma-Beta 1.2 -4.084751 6.484751 0.9281909
Eta-Delta 1.4 -3.884751 6.684751 0.8834072
Gamma-Delta 1.8 -3.484751 7.084751 0.7640759
Gamma-Eta 0.4 -4.884751 5.684751 0.9987373
plot(TukeyHSD(results))
Treatment = as.factor(data$Catalyst)
results = aov(Time~Treatment,data)
summary(results)
Df Sum Sq Mean Sq F value Pr(>F)
Treatment 4 342.8 85.70 18.39 1.77e-06 ***
Residuals 20 93.2 4.66
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Treatment1 = as.factor(data$Catalyst)
Row = as.factor(data$Batch)
Column = as.factor(data$Acid)
results = aov(Time~Row+Column+Treatment1,data)
summary(results)
Df Sum Sq Mean Sq F value Pr(>F)
Row 4 10.0 2.5 0.510 0.730
Column 4 24.4 6.1 1.245 0.344
Treatment1 4 342.8 85.7 17.490 6.03e-05 ***
Residuals 12 58.8 4.9
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1