Paul Spin posted on Friday, December 01, 2017 - 3:19 pm
A relative newbie to Mplus...
I am attempting to model
Y= B0 + B1*LAS + B2*Z + error
where Y is a count variable, LAS is a latent class variable w/ 3 categories, and Z is a vector of covariates.
I am following Web Notes 21 [Section 3.2], which returns class-specific intercepts and slope for each Z. Instead, I would like to get class-independent main effects for Z while still allowing for class-specific intercepts.
Here is my code:
TITLE: STAGE 1: Estimate latent class model; DATA: File = data.csv ; VARIABLE: NAMES = y a1-a8 z; USEVARIABLES = a1-a8 ; CATEGORICAL = a1-a8; CLASSES = c(3); AUXILIARY = y z; ANALYSIS: TYPE = MIXTURE; Savedata: File = lcaoutput.csv ; Save = bchweights;
TITLE: Y on C and Z ; DATA: File = lcaoutput.csv: VARIABLE: NAMES = y a1-a8 z W1-W3 MLC; USEVARIABLES = y z W1-W3 ; CLASSES = c(3); Training = W1-W3(bch); ANALYSIS: TYPE = MIXTURE; MODEL: %Overall% C y on z; %c#1% y on z; %c#2% y on z; %c#3% y on z;
Q1: How to I modify the second input file to obtain what I described above? Q2: How do I test for statistically significant differences in the class-specific intercepts?