Dear Community,
I am currently executing a structural equation model with lavaan and do want to include a nominal exogenous variable. First of all to look for a main effect, but mainly to investigate a moderation effect. I did find this helpful site about categorical variables ( The lavaan Project (ugent.be)) and do wonder if I need a multilevel approach or just a dummy variable. My nominal variable is a manipulation condition with a control group (so including the control group it is 4 groups). There is no order between the groups, as they have different characteristics.
So my first question is:
Do I have to create 3 dummy variables and look for a main effect and in the second step include the interception of each dummy?
In total I have 3 subdimensions of one construct as exogenous variables plus the manipulation.
For one subdimension this would lead me to following code :
Outcome (IV) =~ subdimension1 + Dummy1 + Dummy2 + Dummy3 (without Moderation)
Outcome (IV) =~ subdimension1 Dummy1 + subdimension1 Dummy2 + subdimension* Dummy3 (including Moderation)
I do feel that I am on the wrong path.
Thank you so much in advance.
Best regards