# A 2 x 4 x 3 design, planning the f = .10 main effect of the
# two-level factor A. Two baseline covariates with a modest joint
# R^2 = .25 cut the required total N by roughly a quarter:
ss_power_factorial_ancova(factor_levels = c(2, 4, 3), effect_indices = 1,
f = 0.10, covariate_R2 = 0, n_covariates = 0,
desired_power = 0.80)
ss_power_factorial_ancova(factor_levels = c(2, 4, 3), effect_indices = 1,
f = 0.10, covariate_R2 = 0.25, n_covariates = 2,
desired_power = 0.80)
# Realized power for the three-way interaction at 6 per cell.
ss_power_factorial_ancova(factor_levels = c(2, 4, 3),
effect_indices = c(1, 2, 3), f = 0.15,
covariate_R2 = 0.25, n_covariates = 2,
n_per_cell = 6)
Run the code above in your browser using DataLab