Experts!
I would appreciate a sanity check on my sample size calculation for an upcoming study.
Study Design: We’re using a 2x2 factorial design to evaluate two interventions for reducing the hemodynamic stress response during craniotomy: Ultrasound-Guided Nerve Block (Factor A) and a Helper Drug (Factor B).
The four study arms will be:
- Arm A: Standard Nerve Block + Saline (Placebo)
- Arm B: Standard Nerve Block + Helper Drug
- Arm C: Ultrasound-Guided Nerve Block + Saline (Placebo)
- Arm D: Ultrasound-Guided Nerve Block + Helper Drug
Our primary outcome is the change in Blood Pressure from baseline to the peak response (1 min post-pinning), and our analysis plan is a 2x2 ANCOVA with baseline blood pressure as a covariate.
We are powering the study to detect a main effect for each intervention. For our example below, we will use a small-to-medium effect size, corresponding to a Cohen’s d of 0.3.
> library(pwrss)
>
> cohend = 0.3 ## example Cohen's d from literature
> effect_size_f <- cohend/2 # Cohen's f, for simplicity assume f = d/2
> f2_value <- effect_size_f^2 # f-squared
> # Convert f-squared to eta-squared using: eta2 = f2/(1+f2)
> eta2_value <- f2_value / (1 + f2_value)
>
> # ANCOVA design parameters
> n_way <- 2
> n_levels <- c(2,2)
> n_covariates <- 1 # Baseline Measurment
>
> alpha <- 0.05
> desired_power <- 0.80
>
> result <- pwrss.f.ancova(f2 =f2_value ,n.way = n_way,
+ n.levels = n_levels,
+ n.covariates = n_covariates,
+ alpha = alpha,
+ power = desired_power,
+ verbose = TRUE)
Two-way Analysis of Covariance (ANCOVA)
H0: 'eta2' or 'f2' = 0
HA: 'eta2' or 'f2' > 0
--------------------------------------
Factor A: 2 levels
Factor B: 2 levels
--------------------------------------
effect power n.total ncp df1 df2
A 0.8 351 7.893 1 345.786
B 0.8 351 7.893 1 345.786
A x B 0.8 351 7.893 1 345.786
--------------------------------------
Type I error rate: 0.05
# The output suggests a total sample size of 352 participants (88 per arm).
# Adjusting for Dropout e.g. 10% ==> N/0.9
@f2harrell My question is: Does this overall approach seem sound? Are there any common pitfalls with this method that I might be overlooking?
Thanks in advance.