Complete power analyses for ANCOVA omnibus tests and contrasts. This function does not support within subjects factors.
ANCOVA_analytic(
design,
mu,
n = NULL,
sd,
r2 = NULL,
n_cov,
alpha_level = Superpower_options("alpha_level"),
beta_level = NULL,
cmats = list(),
label_list = NULL,
design_result = NULL,
round_up = TRUE
)
Output from the ANOVA_design function
Vector specifying mean for each condition
Sample size in each condition
Standard deviation for all conditions (or a vector specifying the sd for each condition)
Coefficient of Determination of the model with only the covariates
Number of covariates
Alpha level used to determine statistical significance
Type II error probability (power/100-1)
List of matrices for specific contrasts of interest
An optional list to specify the factor names and condition (recommended, if not used factors and levels are indicated by letters and numbers).
Output from the ANOVA_design function
Logical indicator (default = TRUE) for whether to round up sample size calculations to nearest whole number
One, or two, data frames containing the power analysis results from the power analysis for the omnibus ANCOVA (main_results) or contrast tests (contrast_results). In addition, every F-test (aov_list and con_list) is included in a list of power.htest results. Lastly, a (design_param) list containing the design parameters is also included in the results.
Shieh, G. (2020). Power analysis and sample size planning in ANCOVA designs. Psychometrika, 85(1), 101-120.
# Simple 2x3 ANCOVA
ANCOVA_analytic(
design = "2b*3b",
mu = c(400, 450, 500,
400, 500, 600),
n_cov = 3,
sd = 100,
r2 = .25,
alpha_level = .05,
beta_level = .2,
round_up = TRUE
)
#> Power Analysis Results for ANCOVA
#> Total N Covariates r2 Alpha Level Beta Level Power
#> a 102 3 0.25 0.05 0.1897 81.03
#> b 30 3 0.25 0.05 0.1389 86.11
#> a:b 180 3 0.25 0.05 0.1995 80.05
#>