I am trying to run an analysis to determine whether m mediates the effect of the following X variables on Y.
I have -3 independent categorical variables i.e. level of education (3 categories), level on income( 3 categories) gender(2 categories) and age (continuous) - a mediator which is a continuous variable (m) and - one outcome variable which is an ordered categorical outcome (y1 -y3).
I have looked at the examples in the Mplus textbook however I am still unclear whether I can use model indirect when I have more than one categorical independent variable and if so, do I need to create a dummy variable.
I tried with the following syntax (which failed to run)
Model: m on edu; m on inc; m on gender; m on age; y#1 y#2 on m; yk#1 y#2 on edu; y#1 y#2 on inc; y#1 yk#2 on gender; y#1 y#2 on age;
Model indirect: Y1 y2 ind m edu; Y1 y2 ind m age; Y1 y2 ind m gender; Y1 y2 ind m inc; Y1 y2 via m edu age gender inc;
Analysis: ESTIMATOR = MLR;
Would really appreciate if you could help me with some suggestions how to run this model.