# 1. Two of five groups compared against the reference group, with a
# pooled error term from one model across all five groups.
# Bounds of 5 raw-scale points; alpha_level = .05, so decisions read
# from the 90% CI.
equivalence_c(means = c(70.40, 55.61, 51.91, 65.66, 65.12),
s_anova = 15.67,
c_weights = c(-1, 0, 0, 0, 1),
n = c(113, 74, 76, 80, 61),
delta_upper = 5)
# 2. The same contrast through the direct interface, as when the
# estimate and standard error come from a model with covariates.
res <- equivalence_c(psi_hat = -5.28, se = 2.49, df_error = 399,
delta_upper = 5)
res
attr(res, "verdict")
# 3. A group mean against a fixed benchmark of 68: the constant
# contributes no sampling variability.
equivalence_c(means = c(70.40, 55.61, 51.91, 65.66, 65.12),
s_anova = 15.67,
c_weights = c(1, 0, 0, 0, 0),
n = c(113, 74, 76, 80, 61),
benchmark = 68, delta_upper = 5)
# 4. Asymmetric bounds: a shortfall of 3 matters, an excess of 8 does.
equivalence_c(psi_hat = 1.2, se = 1.1, df_error = 120,
delta_lower = 3, delta_upper = 8)
Run the code above in your browser using DataLab