Three factors are studied:
Each factor has two levels. One replicate of the 2^3 factorial design has eight treatment combinations.
For two blocks, the block degrees of freedom are:
\[ 2-1=1 \]
Therefore, one factorial effect must be confounded with blocks.
We choose the highest-order interaction, ABC, so the main effects and two-factor interactions remain estimable.
The block defining relation is:
\[ I = \text{Block}\times ABC \]
The block assignment is determined by the sign of ABC.
treatments <- data.frame(
Treatment = c("(1)", "a", "b", "ab", "c", "ac", "bc", "abc"),
A = c(-1, 1, -1, 1, -1, 1, -1, 1),
B = c(-1, -1, 1, 1, -1, -1, 1, 1),
C = c(-1, -1, -1, -1, 1, 1, 1, 1)
)
treatments$ABC <- with(treatments, A * B * C)
treatments$Block <- ifelse(
treatments$ABC == -1,
"Block 1",
"Block 2"
)
knitr::kable(
treatments,
caption = "Two-block layout; ABC is confounded with blocks"
)
| Treatment | A | B | C | ABC | Block |
|---|---|---|---|---|---|
| (1) | -1 | -1 | -1 | -1 | Block 1 |
| a | 1 | -1 | -1 | 1 | Block 2 |
| b | -1 | 1 | -1 | 1 | Block 2 |
| ab | 1 | 1 | -1 | -1 | Block 1 |
| c | -1 | -1 | 1 | 1 | Block 2 |
| ac | 1 | -1 | 1 | -1 | Block 1 |
| bc | -1 | 1 | 1 | -1 | Block 1 |
| abc | 1 | 1 | 1 | 1 | Block 2 |
The resulting blocks are:
The block labels can be reversed without changing the confounding structure.
Four blocks require:
\[ 4-1=3 \]
block degrees of freedom. Therefore, three independent factorial effects are confounded with blocks.
To preserve the main effects, choose AB and AC as block generators.
Their generalized interaction is:
\[ (AB)(AC)=A^2BC=BC \]
Therefore, the three effects confounded with blocks are:
\[ \boxed{AB,\ AC,\ BC} \]
The four blocks are determined by the signs of AB and AC.
treatments$AB <- with(treatments, A * B)
treatments$AC <- with(treatments, A * C)
treatments$BC <- with(treatments, B * C)
treatments$Block4 <- paste0(
"Block (AB=",
ifelse(treatments$AB == 1, "+", "-"),
", AC=",
ifelse(treatments$AC == 1, "+", "-"),
")"
)
four_block_layout <- treatments[
order(treatments$Block4, treatments$Treatment),
c("Treatment", "A", "B", "C", "AB", "AC", "BC", "Block4")
]
knitr::kable(
four_block_layout,
caption = "Four-block layout; AB, AC, and BC are confounded with blocks"
)
| Treatment | A | B | C | AB | AC | BC | Block4 | |
|---|---|---|---|---|---|---|---|---|
| 2 | a | 1 | -1 | -1 | -1 | -1 | 1 | Block (AB=-, AC=-) |
| 7 | bc | -1 | 1 | 1 | -1 | -1 | 1 | Block (AB=-, AC=-) |
| 6 | ac | 1 | -1 | 1 | -1 | 1 | -1 | Block (AB=-, AC=+) |
| 3 | b | -1 | 1 | -1 | -1 | 1 | -1 | Block (AB=-, AC=+) |
| 4 | ab | 1 | 1 | -1 | 1 | -1 | -1 | Block (AB=+, AC=-) |
| 5 | c | -1 | -1 | 1 | 1 | -1 | -1 | Block (AB=+, AC=-) |
| 1 | (1) | -1 | -1 | -1 | 1 | 1 | 1 | Block (AB=+, AC=+) |
| 8 | abc | 1 | 1 | 1 | 1 | 1 | 1 | Block (AB=+, AC=+) |
Each block contains two treatment combinations. The three block-confounded effects cannot be estimated separately from block effects.
The observations supplied in the assignment correspond to the two-block layout from Problem 1(b), where ABC is confounded with blocks.
dat <- data.frame(
Treatment = c("(1)", "a", "b", "ab", "c", "ac", "bc", "abc"),
A = c(-1, 1, -1, 1, -1, 1, -1, 1),
B = c(-1, -1, 1, 1, -1, -1, 1, 1),
C = c(-1, -1, -1, -1, 1, 1, 1, 1),
ToolLife = c(22, 32, 35, 55, 44, 40, 60, 39)
)
dat$ABC <- with(dat, A * B * C)
dat$Block <- ifelse(
dat$ABC == -1,
"Block 1",
"Block 2"
)
knitr::kable(
dat,
caption = "Observed tool-life data and block assignment"
)
| Treatment | A | B | C | ToolLife | ABC | Block |
|---|---|---|---|---|---|---|
| (1) | -1 | -1 | -1 | 22 | -1 | Block 1 |
| a | 1 | -1 | -1 | 32 | 1 | Block 2 |
| b | -1 | 1 | -1 | 35 | 1 | Block 2 |
| ab | 1 | 1 | -1 | 55 | -1 | Block 1 |
| c | -1 | -1 | 1 | 44 | 1 | Block 2 |
| ac | 1 | -1 | 1 | 40 | -1 | Block 1 |
| bc | -1 | 1 | 1 | 60 | -1 | Block 1 |
| abc | 1 | 1 | 1 | 39 | 1 | Block 2 |
For a 2^3 design with one replicate, each factorial effect is its contrast divided by:
\[ 2^{3-1}=4 \]
effect_names <- c("A", "B", "C", "AB", "AC", "BC", "ABC")
effect_values <- sapply(effect_names, function(term) {
factors <- strsplit(term, "")[[1]]
sign <- Reduce(
`*`,
lapply(factors, function(x) dat[[x]])
)
sum(sign * dat$ToolLife) / 4
})
effects <- data.frame(
Effect = effect_names,
Estimate = as.numeric(effect_values),
Absolute_Effect = abs(as.numeric(effect_values))
)
knitr::kable(
effects,
digits = 4,
caption = "Estimated factorial effects"
)
| Effect | Estimate | Absolute_Effect |
|---|---|---|
| A | 1.25 | 1.25 |
| B | 12.75 | 12.75 |
| C | 9.75 | 9.75 |
| AB | -1.75 | 1.75 |
| AC | -13.75 | 13.75 |
| BC | -5.25 | 5.25 |
| ABC | -6.75 | 6.75 |
The ABC effect is confounded with the two-block comparison. It is not independently estimable as a treatment effect.
The DoE.base package provides halfnormal() for an
unreplicated factorial model.
if (!requireNamespace("DoE.base", quietly = TRUE)) {
install.packages("DoE.base")
}
library(DoE.base)
model_full <- lm(
ToolLife ~ A * B * C,
data = dat
)
halfnormal(model_full)
effect_ranking <- effects[
order(-effects$Absolute_Effect),
]
knitr::kable(
effect_ranking,
digits = 4,
caption = "Effects ranked by absolute magnitude"
)
| Effect | Estimate | Absolute_Effect | |
|---|---|---|---|
| 5 | AC | -13.75 | 13.75 |
| 2 | B | 12.75 | 12.75 |
| 3 | C | 9.75 | 9.75 |
| 7 | ABC | -6.75 | 6.75 |
| 6 | BC | -5.25 | 5.25 |
| 4 | AB | -1.75 | 1.75 |
| 1 | A | 1.25 | 1.25 |
The half-normal plot is used to judge which effects depart from the straight-line pattern formed by smaller effects.
With only one replicate, there is no independent pure-error estimate. The half-normal plot is therefore a screening tool rather than a conventional replicated ANOVA test.
block_means <- aggregate(
ToolLife ~ Block,
data = dat,
mean
)
knitr::kable(
block_means,
digits = 4,
caption = "Mean tool life by block"
)
| Block | ToolLife |
|---|---|
| Block 1 | 44.25 |
| Block 2 | 37.50 |
block_difference <- diff(block_means$ToolLife)
cat(
"Difference between block means:",
round(block_difference, 4),
"hours\n"
)
## Difference between block means: -6.75 hours
cat(
"Absolute ABC factorial contrast:",
round(abs(effect_values["ABC"]), 4),
"\n"
)
## Absolute ABC factorial contrast: 6.75
Question 3(a): Which effects appear significant?
The largest estimated treatment effects are:
These are the leading candidates for active effects based on magnitude. The ABC contrast represents the block effect and is confounded with the blocks.
Question 3(b): Does the block appear significant?
The two block means differ by 6.75 hours.
However, the block effect is exactly confounded with ABC in this design. Therefore, the data cannot distinguish a block effect from an ABC interaction effect.
The observed block contrast is 6.75 hours, but it cannot be tested independently using this single replicate.