aalfons / robmed

Perform mediation analysis via a fast-and-robust bootstrap test, as well as various other methods
GNU General Public License v3.0
6 stars 0 forks source link

Allow to switch between "product of coefficients" and "difference of coefficients" approach #3

Closed aalfons closed 2 years ago

aalfons commented 7 years ago

Add argument indirect with options "product" (default) and "difference" to function regFitMediation(). This is of course only necessary for robust regressions as they are equivalent for other approaches.

aalfons commented 7 years ago

Sobel test requires "product of coefficients" approach. So whenever the Sobel test is selected, this argument should be ignored. Also give a warning in this case.

aalfons commented 2 years ago

This is not the most pressing issue at the moment, since robmed currently supports only continuous dependent variables and mediators, where under the usual normality assumptions the two approaches are identical at the model.

But when the methodology is extended to, e.g., binary dependent variables or mediators, this becomes important and should be implemented.

aalfons commented 2 years ago

Actually, we should only implement the "product of coefficients" approach. For continuous dependent variables, the two approaches are equivalent under the usual normality assumptions. For binary dependent variables (for which we still need to develop our approach), the two approaches are not equivalent and only the "product of coefficients" approach is reasonable. See, e.g., Rijnhart et al. (2021).