Moderation Analysis with SEM
Hi,
I want to examine the effect of the Moderator "AGE" on the relationship between five latent independent variables (PE, EE, SI, FC and T) on the latent dependent variable BI. I'm conducting the analysis via SEM in JASP. Is it correct that I need to include the independent variable, the moderator and an interaction term (e.g. PE*AGE) into the code? So would this be correct?
BI ~ PE + EE + SI + FC + T + AGE + PE*AGE + EE*AGE + SI*AGE + FC*AGE + T*AGE
Unfortunately, I'm getting this error message.
I'm grateful for your help!!!
Comments
I don't know for sure what the source of your problem is, but just bouncing ideas here: I don't think interaction terms with latent variables are implemented in lavaan (the SEM library JASP uses) yet
Thank you so much! I think the source of the problem is the variable AGE. As long as I don't include it into the regression, everything works fine (see code). As soon as I add it, I get the error. Do I have to specify age first after doing the cfa? It's a normal scale variable in my dataset so I don't see the problem...
#cfa
BI =~ lambda_1_1*BI_1 + lambda_1_2*BI_2 + lambda_1_3*BI_3
T =~ lambda_2_1*T_1 + lambda_2_2*T_2 + lambda_2_3*T_3 + lambda_2_4*T_4
PE =~ lambda_3_1*PE_1 + lambda_3_2*PE_2 + lambda_3_3*PE_3 + lambda_3_4*PE_4
EE =~ lambda_4_1*EE_1 + lambda_4_2*EE_2 + lambda_4_3*EE_3 + lambda_4_4*EE_4
SI =~ lambda_5_1*SI_1 + lambda_5_2*SI_2 + lambda_5_3*SI_3
FC =~ lambda_6_1*FC_1 + lambda_6_2*FC_2 + lambda_6_3*FC_3
SA =~ lambda_7_1*SA_1 + lambda_7_2*SA_2 + lambda_7_3*SA_3 + lambda_7_4*SA_4
PR =~ lambda_8_1*PR_1 + lambda_8_2*PR_3
TS =~ lambda_9_1*TS_1 + lambda_9_2*TS_2 + lambda_9_3*TS_3
#regression
T ~ PE + SA + TS + PR
BI ~ PE + EE + SI + FC + T
I thought about calculating the interaction term as a new variable in my dataset before adding it to the regression function.
Again, this could still be due to the interaction terms. Have you tried including age without interaction terms? My guess is still that the problem is due to interaction terms with latent variables.
I have personally never dealt with this problem, but a cursory google search yields interesting results: