| size.ci.indirect | R Documentation |
Computes the approximate sample size required to estimate a population standardized indirect effect in a simple mediation model. The direct effect of the independent (exogenous) variable on the response variable, controlling for the mediator variable, is assumed to be negligible.
For more details, see Section 1.19 of Bonett (2021, Volume 4)
size.ci.indirect(alpha, cor1, cor2, w)
alpha |
alpha level for 1-alpha confidence |
cor1 |
planning value of correlation between the independent and mediator variables |
cor2 |
planning value of correlation between the mediator and response variables |
w |
desired confidence interval width |
Returns the required sample size
Bonett2021statpsych
size.ci.indirect(.05, .4, .5, .2)
# Should return:
# Sample size
# 106
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.