TITLE: this is an example of a path analysis
with a combination of continuous and
categorical dependent variables
MONTECARLO:
NAMES = y1 y2 u1 x1-x3;
NOBSERVATIONS = 500;
NREPS = 1;
SEED = 53487;
GENERATE = u1(1);
CATEGORICAL = u1;
SAVE = ex3.14.dat;
MODEL MONTECARLO:
[x1-x3@0];
x1-x3@1;
y1 ON x1*.1 x2*.2 x3*.3;
y2 ON x1*.3 x2*.2 x3*.1;
[y1*1 y2*2];
y1*.5; y2*.3;
u1 ON y1*1 y2*-1 x2*2;
[u1$1*0];
u1*.2;
!note that with WLSMV under the Delta parameterization,
!the u residual variances must agree with the metric
!used in the estimation for estimates to be ok, i.e.
!V(u*|x) = 1. This implies that the u1 res variance
!value is determined by u1 on y1 y2 and the u1 res var
MODEL:
y1 ON x1*.1 x2*.2 x3*.3;
y2 ON x1*.3 x2*.2 x3*.1;
[y1*1 y2*2];
y1*.5; y2*.3;
u1 ON y1*1 y2*-1 x2*2;
[u1$1*0];
OUTPUT: TECH9;