powered by
Perform mediation analysis by Baron and Kenny Method
mediationBK( X = NULL, M = NULL, Y = NULL, labels = list(), data, silent = TRUE, indirect.test = TRUE, sig = 0.05 )
name of independent variable
name of mediator variable
name of dependent variable
An optional list of variable names
A data.frame
Logical. Whether or not show summary of regression tests
Logical. Whether or not show results of bda.mediation.test
significant level. default value is 0.05
labels=list(X="cond",M="pmi",Y="reaction") result=mediationBK(labels=labels,data=pmi,silent=FALSE) result
Run the code above in your browser using DataLab