|
|
Moderated mediation command error |
|
Message/Author |
|
Yina posted on Sunday, September 01, 2013 - 6:28 am
|
|
|
I used Mplus to test a moderated mediation model, in which only first stage moderation is hypothesized. X is predictor, Y is outcome variable, M is mediator and W is moderator. I labled coefficients (B1-B4) when the model is specified. However, I get error information that " Unknown variable(s) in an ON statement: (B1)".I guess I might encounter similar warnings with B2-B4 too. Here is my command: TITLE: MODMED MODEL; DEFINE: XW = (X - 2) * (W - 3); DATA: FILE IS MODMED.DAT; VARIABLE: NAMES ARE X M W Y; USEVARIABLES ARE X M W Y XW; CENTERING IS GRANDMEAN (X M W); ANALYSIS: BOOTSTRAP = 2000; MODEL: M ON X(B1) XW(B2); Y ON M X(B3) XW(B4); MODEL CONSTRAINT: NEW (SLOPE_H SLOPE_L SLOPE_D);!h/l refers to when moderator is high or low, d refers to difference SLOPE_H = B1 + B2 * 0.5; SLOPE_L = B1 + B2 * (-0.5); SLOPE_D = SLOPE_H - SLOPE_L; NEW (DIR_H DIR_L DIR_D);!DIR refers to direct effect DIR_H = B3 + B4 * 0.5; DIR_L = B3 + B4 * (-0.5); DIR_D = DIR_H - DIR_L; OUTPUT: SAMPSTAT; CINTERVAL (BCBOOTSTRAP); What am I doing wrong? Thank you! |
|
|
Please send your full output and license number to support@statmodel.com. |
|
Back to top |
|
|