Mplus VERSION 7
MUTHEN & MUTHEN
09/22/2012  10:08 PM

INPUT INSTRUCTIONS

  TITLE:  this is an example of path analysis with cross-
          classified data
  montecarlo:
          names = y1 y2 x w z;
          within = x;
          between = (level2a) w (level2b) z;
          nobs = 2000;
          nreps =1;
          ! 100 level2b units and 20 level2a units:
          csizes = 100[20(1)];
          ncsizes = 1[1];
          save = ex9.25.dat;
  analysis:
          type = crossclassified random;
          estimator = bayes;
          processors = 2;
          biter = (2000);
  model population:
          %within%
          x@1;
          y2 on y1*.5
          x*0;
          y1 on x*.7;
          y1-y2*1;
          %between level2a%
          w@1;
          y1 on w*.6;
          y2 on w*.3;
          y1-y2*.5;
          y1 with y2*0;
          %between level2b%
          z@1;
          y1 on z*.3;
          y2 on z*.6;
          y1-y2*.5;
          y1 with y2*0;
          [y1-y2*1.5];
  model:
          %within%
       !   x@1;
          y2 on y1*.5
          x*0;
          y1 on x*.7;
          y1-y2*1;
          %between level2a%
       !   w@1;
          y1 on w*.6;
          y2 on w*.3;
          y1-y2*.5;
          y1 with y2*0;
          %between level2b%
       !   z@1;
          y1 on z*.3;
          y2 on z*.6;
          y1-y2*.5;
          y1 with y2*0;
          [y1-y2*1.5];

  output: tech8;



INPUT READING TERMINATED NORMALLY



this is an example of path analysis with cross-
classified data

SUMMARY OF ANALYSIS

Number of groups                                                 1
Number of observations                                        2000

Number of replications
    Requested                                                    1
    Completed                                                    1
Value of seed                                                    0

Number of dependent variables                                    2
Number of independent variables                                  3
Number of continuous latent variables                            0

Observed dependent variables

  Continuous
   Y1          Y2

Observed independent variables
   X           W           Z

Variables with special functions

  Within variables
   X

  Level 2a between variables
   W

  Level 2b between variables
   Z


Estimator                                                    BAYES
Specifications for Bayesian Estimation
  Point estimate                                            MEDIAN
  Number of Markov chain Monte Carlo (MCMC) chains               2
  Random seed for the first chain                                0
  Starting value information                           UNPERTURBED
  Treatment of categorical mediator                         LATENT
  Algorithm used for Markov chain Monte Carlo           GIBBS(PX1)
  Convergence criterion                                  0.500D-01
  Maximum number of iterations                               50000
  K-th iteration used for thinning                               1


SUMMARY OF DATA FOR THE FIRST REPLICATION

     Cluster information

     Number of level 2a clusters           20
     Number of level 2b clusters          100






MODEL FIT INFORMATION

Number of Free Parameters                       17



MODEL RESULTS

                           ESTIMATES              S. E.     M. S. E.  95%  % Sig
              Population   Average   Std. Dev.   Average             Cover Coeff
Within Level

 Y2         ON
  Y1               0.500     0.5074     0.0000     0.0235     0.0001 1.000 1.000
  X                0.000    -0.0143     0.0000     0.0284     0.0002 1.000 0.000

 Y1         ON
  X                0.700     0.7226     0.0000     0.0237     0.0005 1.000 1.000

 Residual Variances
  Y1               1.000     1.0372     0.0000     0.0332     0.0014 1.000 1.000
  Y2               1.000     1.0650     0.0000     0.0349     0.0042 1.000 1.000

Between LEVEL2A Level

 Y1         ON
  W                0.600     0.6489     0.0000     0.2019     0.0024 1.000 1.000

 Y2         ON
  W                0.300     0.4953     0.0000     0.2025     0.0381 1.000 1.000

 Y1       WITH
  Y2               0.000     0.0435     0.0000     0.3682     0.0019 1.000 0.000

 Residual Variances
  Y1               0.500     0.9937     0.0000     0.5170     0.2437 1.000 1.000
  Y2               0.500     1.0627     0.0000     0.5109     0.3167 0.000 1.000

Between LEVEL2B Level

 Y1         ON
  Z                0.300     0.3352     0.0000     0.0802     0.0012 1.000 1.000

 Y2         ON
  Z                0.600     0.6501     0.0000     0.0873     0.0025 1.000 1.000

 Y1       WITH
  Y2               0.000     0.0098     0.0000     0.0697     0.0001 1.000 0.000

 Intercepts
  Y1               1.500     1.5615     0.0000     0.3197     0.0038 1.000 1.000
  Y2               1.500     1.7641     0.0000     0.2619     0.0697 1.000 1.000

 Residual Variances
  Y1               0.500     0.5358     0.0000     0.0884     0.0013 1.000 1.000
  Y2               0.500     0.6519     0.0000     0.1093     0.0231 1.000 1.000


TECHNICAL 1 OUTPUT


     PARAMETER SPECIFICATION FOR WITHIN


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                  0             0             0             0             0


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             0             0             0
 Y2                 0             0             0             0             0
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0
 Y2                 0             0
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                  0             0             0             0             0


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             1             0             0
 Y2                 2             0             3             0             0
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 4
 Y2                 0             5
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


     PARAMETER SPECIFICATION FOR BETWEEN LEVEL2A


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                  0             0             0             0             0


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             0             0             0
 Y2                 0             0             0             0             0
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0
 Y2                 0             0
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                  0             0             0             0             0


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             0             6             0
 Y2                 0             0             0             7             0
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 8
 Y2                 9            10
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


     PARAMETER SPECIFICATION FOR BETWEEN LEVEL2B


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                  0             0             0             0             0


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             0             0             0
 Y2                 0             0             0             0             0
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0
 Y2                 0             0
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1                 11            12             0             0             0


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                 0             0             0             0            13
 Y2                 0             0             0             0            14
 X                  0             0             0             0             0
 W                  0             0             0             0             0
 Z                  0             0             0             0             0


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1                15
 Y2                16            17
 X                  0             0             0
 W                  0             0             0             0
 Z                  0             0             0             0             0


     STARTING VALUES FOR WITHIN


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.700         0.000         0.000
 Y2             0.500         0.000         0.000         0.000         0.000
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000
 Y2             0.000         1.000
 X              0.000         0.000         0.500
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


     STARTING VALUES FOR BETWEEN LEVEL2A


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.000         0.600         0.000
 Y2             0.000         0.000         0.000         0.300         0.000
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.500
 Y2             0.000         0.500
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.500
 Z              0.000         0.000         0.000         0.000         0.000


     STARTING VALUES FOR BETWEEN LEVEL2B


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              1.500         1.500         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.000         0.000         0.300
 Y2             0.000         0.000         0.000         0.000         0.600
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.500
 Y2             0.000         0.500
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.500


     POPULATION VALUES FOR WITHIN


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.700         0.000         0.000
 Y2             0.500         0.000         0.000         0.000         0.000
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000
 Y2             0.000         1.000
 X              0.000         0.000         1.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


     POPULATION VALUES FOR BETWEEN LEVEL2A


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.000         0.600         0.000
 Y2             0.000         0.000         0.000         0.300         0.000
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.500
 Y2             0.000         0.500
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         1.000
 Z              0.000         0.000         0.000         0.000         0.000


     POPULATION VALUES FOR BETWEEN LEVEL2B


           NU
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              0.000         0.000         0.000         0.000         0.000


           LAMBDA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             1.000         0.000         0.000         0.000         0.000
 Y2             0.000         1.000         0.000         0.000         0.000
 X              0.000         0.000         1.000         0.000         0.000
 W              0.000         0.000         0.000         1.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000


           THETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000
 Y2             0.000         0.000
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           ALPHA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 1              1.500         1.500         0.000         0.000         0.000


           BETA
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.000         0.000         0.000         0.000         0.300
 Y2             0.000         0.000         0.000         0.000         0.600
 X              0.000         0.000         0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         0.000


           PSI
              Y1            Y2            X             W             Z
              ________      ________      ________      ________      ________
 Y1             0.500
 Y2             0.000         0.500
 X              0.000         0.000         0.000
 W              0.000         0.000         0.000         0.000
 Z              0.000         0.000         0.000         0.000         1.000



     PRIORS FOR ALL PARAMETERS            PRIOR MEAN      PRIOR VARIANCE     PRIOR STD. DEV.

     Parameter 1~N(0.000,infinity)           0.0000            infinity            infinity
     Parameter 2~N(0.000,infinity)           0.0000            infinity            infinity
     Parameter 3~N(0.000,infinity)           0.0000            infinity            infinity
     Parameter 4~IG(-1.000,0.000)          infinity            infinity            infinity
     Parameter 5~IG(-1.000,0.000)          infinity            infinity            infinity
     Parameter 6~N(0.000,infinity)           0.0000            infinity            infinity
     Parameter 7~N(0.000,infinity)           0.0000            infinity            infinity
     Parameter 8~IW(0.000,-3)              infinity            infinity            infinity
     Parameter 9~IW(0.000,-3)              infinity            infinity            infinity
     Parameter 10~IW(0.000,-3)             infinity            infinity            infinity
     Parameter 11~N(0.000,infinity)          0.0000            infinity            infinity
     Parameter 12~N(0.000,infinity)          0.0000            infinity            infinity
     Parameter 13~N(0.000,infinity)          0.0000            infinity            infinity
     Parameter 14~N(0.000,infinity)          0.0000            infinity            infinity
     Parameter 15~IW(0.000,-3)             infinity            infinity            infinity
     Parameter 16~IW(0.000,-3)             infinity            infinity            infinity
     Parameter 17~IW(0.000,-3)             infinity            infinity            infinity


TECHNICAL 8 OUTPUT

   TECHNICAL 8 OUTPUT FOR BAYES ESTIMATION

     CHAIN    BSEED
     1        0
     2        285380

     REPLICATION 1:


                     POTENTIAL       PARAMETER WITH
     ITERATION    SCALE REDUCTION      HIGHEST PSR
     100              1.943               11
     200              1.106               12
     300              1.206               12
     400              1.618               12
     500              2.132               12
     600              1.752               12
     700              1.235               12
     800              1.024               12
     900              1.018               12
     1000             1.110               12
     1100             1.221               12
     1200             1.265               12
     1300             1.277               12
     1400             1.326               12
     1500             1.363               11
     1600             1.357               11
     1700             1.314               11
     1800             1.312               11
     1900             1.342               11
     2000             1.319               11
     2100             1.291               11
     2200             1.397               11
     2300             1.494               11
     2400             1.355               11
     2500             1.153               11
     2600             1.061               11



     Kolmogorov-Smirnov comparing posterior distributions across chains 1 and 2 using 100 draws.





     Parameter   KS Statistic P-value
     Parameter 11    0.4600    0.0000

     REPLICATION 1:


     THE KOLMOGOROV-SMIRNOV DISTRIBUTION TEST FOR PARAMETER 11 HAS A P-VALUE 0.0000,
     INDICATING DISCREPANT POSTERIOR DISTRIBUTIONS IN THE DIFFERENT MCMC CHAINS.
     THIS MAY INDICATE NON-CONVERGENCE DUE TO AN INSUFFICIENT NUMBER OF MCMC ITERATIONS OR IT MAY
     INDICATE A NON-IDENTIFIED MODEL. SPECIFY A LARGER NUMBER OF MCMC ITERATIONS USING THE FBITER
     OPTION OF THE ANALYSIS COMMAND TO INVESTIGATE THE PROBLEM.

     Parameter 12    0.2300    0.0082
     Parameter 8    0.1700    0.0994
     Parameter 9    0.1500    0.1930
     Parameter 6    0.1300    0.3439
     Parameter 1    0.1200    0.4431
     Parameter 13    0.1100    0.5560
     Parameter 10    0.1100    0.5560
     Parameter 17    0.1000    0.6766
     Parameter 14    0.0900    0.7942
     Parameter 15    0.0700    0.9610
     Parameter 16    0.0600    0.9921
     Parameter 7    0.0500    0.9995
     Parameter 3    0.0400    1.0000
     Parameter 5    0.0300    1.0000
     Parameter 2    0.0200    1.0000
     Parameter 4    0.0100    1.0000



     Simulated prior distributions

     Parameter       Prior Mean  Prior Variance  Prior Std. Dev.


     Parameter 1 Improper Prior
     Parameter 2 Improper Prior
     Parameter 3 Improper Prior
     Parameter 4 Improper Prior
     Parameter 5 Improper Prior
     Parameter 6 Improper Prior
     Parameter 7 Improper Prior
     Parameter 8 Improper Prior
     Parameter 9 Improper Prior
     Parameter 10 Improper Prior
     Parameter 11 Improper Prior
     Parameter 12 Improper Prior
     Parameter 13 Improper Prior
     Parameter 14 Improper Prior
     Parameter 15 Improper Prior
     Parameter 16 Improper Prior
     Parameter 17 Improper Prior


SAVEDATA INFORMATION

  Order of variables

    Y1
    Y2
    X
    W
    Z
    LEVEL2A
    LEVEL2B

  Save file
    ex9.25.dat

  Save file format           Free
  Save file record length    10000


     Beginning Time:  22:08:52
        Ending Time:  22:08:53
       Elapsed Time:  00:00:01



MUTHEN & MUTHEN
3463 Stoner Ave.
Los Angeles, CA  90066

Tel: (310) 391-9971
Fax: (310) 391-8971
Web: www.StatModel.com
Support: Support@StatModel.com

Copyright (c) 1998-2012 Muthen & Muthen

Back to examples