Processing math: 100%

User Tools

Site Tools


manual:mediation01

Power for Simple Mediation via Sobel test

Description

Consider a simple mediation model

mi=a0+axi+emi yi=b0+bmi+cxi+eyi

where emiN(0,σ2em) and eyiN(0,σ2ey). The mediation effect is ab=ab.

The Sobel test statistic is

Z=ˆaˆbˆσab

where ˆσ2ab=ˆa2ˆσ2b+ˆb2ˆσ2a. From regression analysis, we have

ˆσ2a=σ2emnσ2x

ˆσ2b=σ2eynσ2m(1ρ2mx)

Furthermore, because ˆa=ρxmσm/σx, we have ρxm=ˆaσx/σm and σ2em=σ2m(1ρ2mx)=σ2ma2σ2x. Then

ˆσ2a=σ2ma2σ2xnσ2x

ˆσ2b=σ2eyn(σ2ma2σ2x)

Therefore, the Sobel test depends on the sample size, the coefficients a and b, the variances of x and m as well as their correlation, and the residual variance of y denoted by ˆσ2ey as in

Z=ˆaˆbˆa2σ2eyn(σ2ma2σ2x)+ˆb2σ2ma2σ2xnσ2x

To calculate power, one need to provide information on (1) sample size, (2) coefficient a, (3) coefficient b, (4) variance of x (σ2x), (5) variance of m (σ2m), (6) error variance for y (σ2ey), and (7) the significance level α. If the power is provided, the needed sample size can also be calculated.

Arguments

Among (1) sample size, (2) coefficient a, (3) coefficient b, (4) variance of x (σ2x), (5) variance of m (σ2m), (6) error variance for y (σ2ey), (7) the significance level α, and (8) power, one and only one can be left blank.

Sample Size

Provide the number of observations per group. Multiple sample sizes can be provided in two ways. First, multiple sample sizes can be supplied separated by white spaces, e.g., 100 150 200 will calculate power for the three sample sizes. A sequence of sample sizes can be generated using the method s:e:i with s denoting the starting sample size, e as ending sample size, and i as the interval. For example, 100:150:10 will generate a sequence 100 110 120 130 140 150.

By default, the sample size is 100.

Paths a and b

The paths in the model.

Variances of x and m

The marginal variances for x and m.

Error Variance of y

The variance of the error or residual σ2ey

Significance Level (alpha)

The significance level (Type I error rate) for power calculation withe the default 0.05.

Power

The power of the test.

Power curve

Whether to generate the power curve.

Note

A note (less than 200 characters) can be provided to provide basic information on the analysis.

Output

The output lists the related information about this power analysis. The output is given as a matrix.

   N Power   a   b varx varm varey alpha
 100 0.802 0.4 0.4    1    1     1  0.05

Examples

Methods

References

manual/mediation01.txt · Last modified: 2024/09/19 12:24 (external edit)