A synthetic data set with 25 observations in each of the four combinations of treatment and pretest assignment. It is kept as a second example because two of its features make different analyses of the same effect disagree:
Format
A data frame with 100 rows and 4 variables:
- y_post
Numeric posttest score.
- treat
Treatment indicator: 0 = control, 1 = treatment.
- pretested
Pretest indicator: 0 = not pretested, 1 = pretested.
- y_pre
Numeric pretest score. Structurally missing for participants assigned to the unpretested groups.
Details
among pretested participants, the pretest and posttest are negatively correlated (r = -0.14); and
the pretested treatment group's mean pretest score is about 4.5 points higher than the pretested control group's.
As a result, unadjusted, ANCOVA, and gain-score estimates of the treatment
effect among pretested participants differ markedly (see
compare_solomon_methods() and vignette("getting-started")). The
parameters used to generate these data were not recorded, so their true
effects are unknown. For the primary example with documented true values,
see solomon_example.