Compute Power for Mediated (Indirect) Effects Requires correlations between all variables as sample size.
med(rxm1, rxm2 = 0, rxm3 = 0, rxm4 = 0, rxy, rym1, rym2 = 0, rym3 = 0, rym4 = 0, rm1m2 = 0, rm1m3 = 0, rm1m4 = 0, rm2m3 = 0, rm2m4 = 0, rm3m4 = 0, alpha = 0.05, mvars, n)
Correlation between predictor (x) and first mediator (m1)
Correlation between predictor (x) and second mediator (m2)
Correlation between predictor (x) and third mediator (m3)
Correlation between predictor (x) and fourth mediator (m4)
Correlation between DV (y) and predictor (x)
Correlation between DV (y) and first mediator (m1)
Correlation between DV (y) and second mediator (m2)
Correlation DV (y) and third mediator (m3)
Correlation DV (y) and fourth mediator (m4)
Correlation first mediator (m1) and second mediator (m2)
Correlation first mediator (m1) and third mediator (m3)
Correlation first mediator (m1) and fourth mediator (m4)
Correlation second mediator (m2) and third mediator (m3)
Correlation second mediator (m2) and fourth mediator (m4)
Correlation third mediator (m3) and fourth mediator (m4)
Type I error (default is .05)
Number of Mediators
Sample size
Power for Mediated (Indirect) Effects
# NOT RUN { med(rxm1=.25, rxy=-.35, rym1=-.5,mvars=1, n=150) med(rxm1=.3, rxm2=.3, rxm3=.25, rxy=-.35, rym1=-.5,rym2=-.5, rym3 = -.5, rm1m2=.7, rm1m3=.4,rm2m3=.4, mvars=3, n=150) # }
Run the code above in your browser using DataLab