Comparing dish washing detergents
dishwash.Rd
An experiment was carried out to compare dish washing detergents. Standard plates were soiled with standard dirt, and an operator then washed the plates in a detergent solution one at a time. The response variable was the number of plates washed before the foam disappeared. Three basins were set up, with an operator for each, and the three Operators took care to wash at the same rate. A different detergent was used in each basin. Thus the experimental unit was a single washing-up session in one basin, and the units were grouped in blocks of three (being the washing-up sessions carried out simultaneously). Since there were nine detergents to compare in blocks of size three, a balanced incomplete block design was used.
Format
A data frame with 36 rows and 3 columns:
- block
Washing up session. Factor with levels '1' to '12'
- detergent
Detergent brand. Factor with levels '1' to '9'
- plates
Number of plates washed until the foam disappeared
Source
John, P.W.M. (1961) An application of a balanced incomplete block design, Technometrics, 3, 51-54.
Examples
library(dplyr)
#> Error in library(dplyr): there is no package called ‘dplyr’
library(tidyr)
#> Error in library(tidyr): there is no package called ‘tidyr’
library(gt)
#> Error in library(gt): there is no package called ‘gt’
library(hsds)
# Generate all possible cases of detergent and block, then add the recorded
# values from the experiment
all_cases <- dishwash %>%
expand(block, detergent) %>%
left_join(dishwash, by = join_by(block, detergent))
#> Error in dishwash %>% expand(block, detergent) %>% left_join(dishwash, by = join_by(block, detergent)): could not find function "%>%"
# Display as a visually appealling table, showing the incomplete blocked design
# structure
all_cases %>%
labelled::set_variable_labels(plates = NULL) %>%
pivot_wider(
names_from = "detergent",
values_from = "plates"
) %>%
gt() %>%
sub_missing() %>%
cols_label(block ~ "Block") %>%
tab_spanner("Detergent", columns = -block) %>%
cols_width(everything() ~ px(40))
#> Error in all_cases %>% labelled::set_variable_labels(plates = NULL) %>% pivot_wider(names_from = "detergent", values_from = "plates") %>% gt() %>% sub_missing() %>% cols_label(block ~ "Block") %>% tab_spanner("Detergent", columns = -block) %>% cols_width(everything() ~ px(40)): could not find function "%>%"