```Mplus VERSION 8
MUTHEN & MUTHEN
04/10/2017   3:40 AM

INPUT INSTRUCTIONS

Title: two-level reg of y on x with random AR(1),
random intercept, random slope, and random variance

MONTECARLO:  NAMES ARE y x w xm;
NOBS = 5000;
NREP = 1;
NCSIZES = 1;
CSIZES = 100(50);
lagged = y(1) x(1);
within = x;
between = w xm;
save = ex9.31.dat;

ANALYSIS:   TYPE = TWOLEVEL RANDOM;
estimator=bayes;
proc=2;
biter=(1000);

MODEL POPULATION:

%WITHIN%
x*1;
sx | y on x;
sy | y on y&1;
logv | y;
x on x&1*.5;

%BETWEEN%
w-xm*1;
[sx*.7]; [sy*.2]; [logv*0];
y*0.3; sx*0.5; sy*.01; logv*.1;
y on w*.5 xm*.3;
sy on w*.1 xm*.05;
sx on w*.3 xm*.4;
logv on w*.3 xm*.1;

MODEL:

%WITHIN%
x*1;
sx | y on x;
sy | y on y&1;
logv | y;
x on x&1*.5;

%BETWEEN%

[sx*.7]; [sy*.2]; [logv*0];
y*0.3; sx*0.5; sy*.01; logv*.1;
y on w*.5 xm*.3;
sy on w*.1 xm*.05;
sx on w*.3 xm*.4;
logv on w*.3 xm*.1;

output:
tech8;

two-level reg of y on x with random AR(1),
random intercept, random slope, and random variance

SUMMARY OF ANALYSIS

Number of groups                                                 1
Number of observations                                        5000

Number of replications
Requested                                                    1
Completed                                                    1
Value of seed                                                    0

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

Observed dependent variables

Continuous
Y           X

Observed independent variables
W           XM          Y&1         X&1

Continuous latent variables
SX          SY          LOGV

Variables with special functions

Within variables
X           Y&1         X&1

Between variables
W           XM

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

Size (s)    Number of clusters of Size s

50           100

MODEL FIT INFORMATION

Number of Free Parameters                       19

Information Criteria

Deviance (DIC)

Mean                             28942.243
Std Dev                              0.000
Number of successful computations        1

Proportions                   Percentiles
Expected    Observed         Expected       Observed
0.990       0.000        28942.243      28942.243
0.980       0.000        28942.243      28942.243
0.950       0.000        28942.243      28942.243
0.900       0.000        28942.243      28942.243
0.800       0.000        28942.243      28942.243
0.700       0.000        28942.243      28942.243
0.500       0.000        28942.243      28942.243
0.300       0.000        28942.243      28942.243
0.200       0.000        28942.243      28942.243
0.100       0.000        28942.243      28942.243
0.050       0.000        28942.243      28942.243
0.020       0.000        28942.243      28942.243
0.010       0.000        28942.243      28942.243

Estimated Number of Parameters (pD)

Mean                               332.607
Std Dev                              0.000
Number of successful computations        1

Proportions                   Percentiles
Expected    Observed         Expected       Observed
0.990       0.000          332.607        332.607
0.980       0.000          332.607        332.607
0.950       0.000          332.607        332.607
0.900       0.000          332.607        332.607
0.800       0.000          332.607        332.607
0.700       0.000          332.607        332.607
0.500       0.000          332.607        332.607
0.300       0.000          332.607        332.607
0.200       0.000          332.607        332.607
0.100       0.000          332.607        332.607
0.050       0.000          332.607        332.607
0.020       0.000          332.607        332.607
0.010       0.000          332.607        332.607

MODEL RESULTS

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

X          ON
X&1                 0.500     0.4885     0.0000     0.0123     0.0001 1.000 1.000

Intercepts
X                   0.000     0.0135     0.0000     0.0144     0.0002 1.000 0.000

Residual Variances
X                   1.000     1.0014     0.0000     0.0206     0.0000 1.000 1.000

Between Level

SY         ON
W                   0.100     0.1189     0.0000     0.0151     0.0004 1.000 1.000
XM                  0.050     0.0522     0.0000     0.0137     0.0000 1.000 1.000

SX         ON
W                   0.300     0.2939     0.0000     0.0942     0.0000 1.000 1.000
XM                  0.400     0.3489     0.0000     0.0829     0.0026 1.000 1.000

LOGV       ON
W                   0.300     0.3266     0.0000     0.0445     0.0007 1.000 1.000
XM                  0.100     0.0539     0.0000     0.0382     0.0021 1.000 0.000

Y          ON
W                   0.500     0.4848     0.0000     0.0787     0.0002 1.000 1.000
XM                  0.300     0.2931     0.0000     0.0662     0.0000 1.000 1.000

Intercepts
Y                   0.000    -0.0216     0.0000     0.0661     0.0005 1.000 0.000
SX                  0.700     0.7716     0.0000     0.0827     0.0051 1.000 1.000
SY                  0.200     0.1884     0.0000     0.0131     0.0001 1.000 1.000
LOGV                0.000     0.0566     0.0000     0.0400     0.0032 1.000 0.000

Residual Variances
Y                   0.300     0.3767     0.0000     0.0614     0.0059 1.000 1.000
SX                  0.500     0.6516     0.0000     0.0998     0.0230 1.000 1.000
SY                  0.010     0.0075     0.0000     0.0021     0.0000 1.000 1.000
LOGV                0.100     0.0950     0.0000     0.0214     0.0000 1.000 1.000

CORRELATIONS AND MEAN SQUARE ERROR OF THE TRUE FACTOR VALUES AND THE FACTOR SCORES

CORRELATIONS                MEAN SQUARE ERROR
Average    Std. Dev.           Average    Std. Dev.
SX                  0.987       0.000              0.140       0.000
SY                  0.824       0.000              0.080       0.000
LOGV                0.894       0.000              0.183       0.000
Y                   0.979       0.000              0.159       0.000

TECHNICAL 1 OUTPUT

PARAMETER SPECIFICATION FOR WITHIN

NU
Y             X             Y&1           X&1
________      ________      ________      ________
0             0             0             0

LAMBDA
Y             X             Y&1           X&1
________      ________      ________      ________
Y                  0             0             0             0
X                  0             0             0             0
Y&1                0             0             0             0
X&1                0             0             0             0

THETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y                  0
X                  0             0
Y&1                0             0             0
X&1                0             0             0             0

ALPHA
Y             X             Y&1           X&1
________      ________      ________      ________
0             1             0             0

BETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y                  0             0             0             0
X                  0             0             0             2
Y&1                0             0             0             0
X&1                0             0             0             0

PSI
Y             X             Y&1           X&1
________      ________      ________      ________
Y                  0
X                  0             3
Y&1                0             0             0
X&1                0             0             0             0

PARAMETER SPECIFICATION FOR BETWEEN

NU
Y             W             XM
________      ________      ________
0             0             0

LAMBDA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
Y                  0             0             0             0             0
W                  0             0             0             0             0
XM                 0             0             0             0             0

LAMBDA
XM
________
Y                  0
W                  0
XM                 0

THETA
Y             W             XM
________      ________      ________
Y                  0
W                  0             0
XM                 0             0             0

ALPHA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
4             5             6             7             0

ALPHA
XM
________
0

BETA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX                 0             0             0             0             8
SY                 0             0             0             0            10
LOGV               0             0             0             0            12
Y                  0             0             0             0            14
W                  0             0             0             0             0
XM                 0             0             0             0             0

BETA
XM
________
SX                 9
SY                11
LOGV              13
Y                 15
W                  0
XM                 0

PSI
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX                16
SY                 0            17
LOGV               0             0            18
Y                  0             0             0            19
W                  0             0             0             0             0
XM                 0             0             0             0             0

PSI
XM
________
XM                 0

STARTING VALUES FOR WITHIN

NU
Y             X             Y&1           X&1
________      ________      ________      ________
0.000         0.000         0.000         0.000

LAMBDA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              1.000         0.000         0.000         0.000
X              0.000         1.000         0.000         0.000
Y&1            0.000         0.000         1.000         0.000
X&1            0.000         0.000         0.000         1.000

THETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000
X              0.000         0.000
Y&1            0.000         0.000         0.000
X&1            0.000         0.000         0.000         0.000

ALPHA
Y             X             Y&1           X&1
________      ________      ________      ________
0.000         0.000         0.000         0.000

BETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000         0.000         0.000         0.000
X              0.000         0.000         0.000         0.500
Y&1            0.000         0.000         0.000         0.000
X&1            0.000         0.000         0.000         0.000

PSI
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000
X              0.000         1.000
Y&1            0.000         0.000         0.500
X&1            0.000         0.000         0.000         0.500

STARTING VALUES FOR BETWEEN

NU
Y             W             XM
________      ________      ________
0.000         0.000         0.000

LAMBDA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
Y              0.000         0.000         0.000         1.000         0.000
W              0.000         0.000         0.000         0.000         1.000
XM             0.000         0.000         0.000         0.000         0.000

LAMBDA
XM
________
Y              0.000
W              0.000
XM             1.000

THETA
Y             W             XM
________      ________      ________
Y              0.000
W              0.000         0.000
XM             0.000         0.000         0.000

ALPHA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
0.700         0.200         0.000         0.000         0.000

ALPHA
XM
________
0.000

BETA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX             0.000         0.000         0.000         0.000         0.300
SY             0.000         0.000         0.000         0.000         0.100
LOGV           0.000         0.000         0.000         0.000         0.300
Y              0.000         0.000         0.000         0.000         0.500
W              0.000         0.000         0.000         0.000         0.000
XM             0.000         0.000         0.000         0.000         0.000

BETA
XM
________
SX             0.400
SY             0.050
LOGV           0.100
Y              0.300
W              0.000
XM             0.000

PSI
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX             0.500
SY             0.000         0.010
LOGV           0.000         0.000         0.100
Y              0.000         0.000         0.000         0.300
W              0.000         0.000         0.000         0.000         0.500
XM             0.000         0.000         0.000         0.000         0.000

PSI
XM
________
XM             0.500

POPULATION VALUES FOR WITHIN

NU
Y             X             Y&1           X&1
________      ________      ________      ________
0.000         0.000         0.000         0.000

LAMBDA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              1.000         0.000         0.000         0.000
X              0.000         1.000         0.000         0.000
Y&1            0.000         0.000         1.000         0.000
X&1            0.000         0.000         0.000         1.000

THETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000
X              0.000         0.000
Y&1            0.000         0.000         0.000
X&1            0.000         0.000         0.000         0.000

ALPHA
Y             X             Y&1           X&1
________      ________      ________      ________
0.000         0.000         0.000         0.000

BETA
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000         0.000         0.000         0.000
X              0.000         0.000         0.000         0.500
Y&1            0.000         0.000         0.000         0.000
X&1            0.000         0.000         0.000         0.000

PSI
Y             X             Y&1           X&1
________      ________      ________      ________
Y              0.000
X              0.000         1.000
Y&1            0.000         0.000         1.000
X&1            0.000         0.000         0.000         1.000

POPULATION VALUES FOR BETWEEN

NU
Y             W             XM
________      ________      ________
0.000         0.000         0.000

LAMBDA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
Y              0.000         0.000         0.000         1.000         0.000
W              0.000         0.000         0.000         0.000         1.000
XM             0.000         0.000         0.000         0.000         0.000

LAMBDA
XM
________
Y              0.000
W              0.000
XM             1.000

THETA
Y             W             XM
________      ________      ________
Y              0.000
W              0.000         0.000
XM             0.000         0.000         0.000

ALPHA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
0.700         0.200         0.000         0.000         0.000

ALPHA
XM
________
0.000

BETA
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX             0.000         0.000         0.000         0.000         0.300
SY             0.000         0.000         0.000         0.000         0.100
LOGV           0.000         0.000         0.000         0.000         0.300
Y              0.000         0.000         0.000         0.000         0.500
W              0.000         0.000         0.000         0.000         0.000
XM             0.000         0.000         0.000         0.000         0.000

BETA
XM
________
SX             0.400
SY             0.050
LOGV           0.100
Y              0.300
W              0.000
XM             0.000

PSI
SX            SY            LOGV          Y             W
________      ________      ________      ________      ________
SX             0.500
SY             0.000         0.010
LOGV           0.000         0.000         0.100
Y              0.000         0.000         0.000         0.300
W              0.000         0.000         0.000         0.000         1.000
XM             0.000         0.000         0.000         0.000         0.000

PSI
XM
________
XM             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~IG(-1.000,0.000)          infinity            infinity            infinity
Parameter 4~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 5~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 6~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 7~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 8~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 9~N(0.000,infinity)           0.0000            infinity            infinity
Parameter 10~N(0.000,infinity)          0.0000            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~N(0.000,infinity)          0.0000            infinity            infinity
Parameter 16~IG(-1.000,0.000)         infinity            infinity            infinity
Parameter 17~IG(-1.000,0.000)         infinity            infinity            infinity
Parameter 18~IG(-1.000,0.000)         infinity            infinity            infinity
Parameter 19~IG(-1.000,0.000)         infinity            infinity            infinity

TECHNICAL 8 OUTPUT

REPLICATION 1:

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

Parameter   KS Statistic P-value
Parameter 4    0.0900    0.7942
Parameter 15    0.0900    0.7942
Parameter 8    0.0800    0.8938
Parameter 16    0.0700    0.9610
Parameter 7    0.0700    0.9610
Parameter 9    0.0500    0.9995
Parameter 14    0.0500    0.9995
Parameter 12    0.0500    0.9995
Parameter 13    0.0500    0.9995
Parameter 19    0.0500    0.9995
Parameter 3    0.0200    1.0000
Parameter 6    0.0200    1.0000
Parameter 10    0.0100    1.0000
Parameter 2    0.0000    1.0000
Parameter 11    0.0000    1.0000
Parameter 5    0.0000    1.0000
Parameter 17    0.0000    1.0000
Parameter 18    0.0000    1.0000
Parameter 1    0.0000    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
Parameter 18 Improper Prior
Parameter 19 Improper Prior

TECHNICAL 8 OUTPUT FOR BAYES ESTIMATION

CHAIN    BSEED
1        0
2        285380

REPLICATION 1:

POTENTIAL       PARAMETER WITH
ITERATION    SCALE REDUCTION      HIGHEST PSR
100              1.113               6
200              1.037               13
300              1.068               11
400              1.081               11
500              1.024               18
600              1.021               13
700              1.014               11
800              1.009               12
900              1.008               12
1000             1.006               12

SAVEDATA INFORMATION

Order of variables

Y
X
W
XM
CLUSTER
Y&1
X&1

Save file
ex9.31.dat

Save file format           Free
Save file record length    10000

Beginning Time:  03:40:53
Ending Time:  03:41:05
Elapsed Time:  00:00:12

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-2017 Muthen & Muthen
```