------------------------------------------------------------------------------------------------------------------------------------------------------
      name:  STATA_Chapter10b
       log:  C:\Dropbox\PilesOfVariance\Chapter10b\STATA\STATA_Chapter10b_Output.smcl
  log type:  smcl
 opened on:  30 Jan 2015, 12:19:45


. . display as result "Chapter 10b: Descriptive Statistics for Time-Varying Variables" Chapter 10b: Descriptive Statistics for Time-Varying Variables

. summarize symptoms posaff

Variable | Obs Mean Std. Dev. Min Max -------------+-------------------------------------------------------- symptoms | 2752 1.660974 1.42964 0 5 posaff | 2747 2.580269 .7319597 0 4

. . display as result "Ch 10b: Empty Means, Single-Level Model for the Variance for Symptoms" Ch 10b: Empty Means, Single-Level Model for the Variance for Symptoms

. display as result "Independent Observations" Independent Observations

. mixed symptoms , /// > || personid: , noconstant variance mle covariance(unstructured) /// > || burst: , noconstant covariance(unstructured), Note: all random-effects equations are empty; model is linear regression

Mixed-effects ML regression Number of obs = 2752

Wald chi2(0) = . Log likelihood = -4888.0461 Prob > chi2 = .

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 1.660974 .0272473 60.96 0.000 1.60757 1.714378 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ var(Residual) | 2.043128 .055079 1.937978 2.153984 ------------------------------------------------------------------------------

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -4888.046 2 9780.092 9785.456 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estimates store FitEmpty1S,

. . display as result "Ch 10b: Empty Means, Two-Level Model for the Variance for Symptoms" Ch 10b: Empty Means, Two-Level Model for the Variance for Symptoms

. display as result "Sessions Within Burst*Persons" Sessions Within Burst*Persons

. mixed symptoms , /// > || personid: , noconstant variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3886.2366 Iteration 1: log likelihood = -3886.2366

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(0) = . Log likelihood = -3886.2366 Prob > chi2 = .

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 1.66991 .057583 29.00 0.000 1.557049 1.78277 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: (empty) | -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | 1.424997 .1010434 1.240101 1.63746 -----------------------------+------------------------------------------------ var(Residual) | .6302559 .0186331 .5947736 .6678549 ------------------------------------------------------------------------------ LR test vs. linear regression: chibar2(01) = 2003.62 Prob >= chibar2 = 0.0000

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3886.237 3 7778.473 7786.52 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat wcorrelation, covariance,

Covariances for personid = 101 burst = 1:

obs | 1 2 3 -------------+------------------------ 1 | 2.055 2 | 1.425 2.055 3 | 1.425 1.425 2.055

. estat wcorrelation,

Standard deviations and correlations for personid = 101 burst = 1:

Standard deviations:

obs | 1 2 3 -------------+------------------------ sd | 1.434 1.434 1.434

Correlations:

obs | 1 2 3 -------------+------------------------ 1 | 1.000 2 | 0.693 1.000 3 | 0.693 0.693 1.000

. estimates store FitEmpty2S,

. . display as result "Eq 10b.5: Empty Means, Three-Level Model for the Variance for Symptoms" Eq 10b.5: Empty Means, Three-Level Model for the Variance for Symptoms

. display as result "Level-1 Sessions Within Level-2 Bursts Within Level-3 Persons" Level-1 Sessions Within Level-2 Bursts Within Level-3 Persons

. mixed symptoms , /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3762.2643 Iteration 1: log likelihood = -3762.2643

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(0) = . Log likelihood = -3762.2643 Prob > chi2 = .

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 1.704674 .1063595 16.03 0.000 1.496213 1.913135 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | 1.077332 .169218 .7918629 1.465713 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .4255335 .0403582 .3533497 .5124635 -----------------------------+------------------------------------------------ var(Residual) | .6304876 .0186414 .5949896 .6681033 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2251.56 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3762.264 4 7532.529 7543.257 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat icc,

Intraclass correlation

------------------------------------------------------------------------------ Level | ICC Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid | .5049946 .0412796 .4246583 .5850739 burst|personid | .7044617 .0245813 .654126 .7502685 ------------------------------------------------------------------------------

. estat wcorrelation, covariance,

Covariances for personid = 101 burst = 1:

obs | 1 2 3 -------------+------------------------ 1 | 2.133 2 | 1.503 2.133 3 | 1.503 1.503 2.133

. estat wcorrelation,

Standard deviations and correlations for personid = 101 burst = 1:

Standard deviations:

obs | 1 2 3 -------------+------------------------ sd | 1.461 1.461 1.461

Correlations:

obs | 1 2 3 -------------+------------------------ 1 | 1.000 2 | 0.704 1.000 3 | 0.704 0.704 1.000

. estimates store FitEmpty3S,

. lrtest FitEmpty3S FitEmpty2S,

Likelihood-ratio test LR chi2(1) = 247.94 (Assumption: FitEmpty2S nested in FitEmpty3S) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Empty Means, Single-Level Model for the Variance for Positive Affect" Ch 10b: Empty Means, Single-Level Model for the Variance for Positive Affect

. display as result "Independent Observations" Independent Observations

. mixed posaff , /// > || personid: , noconstant variance mle covariance(unstructured) /// > || burst: , noconstant covariance(unstructured), Note: all random-effects equations are empty; model is linear regression

Mixed-effects ML regression Number of obs = 2747

Wald chi2(0) = . Log likelihood = -3040.1781 Prob > chi2 = .

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 2.580269 .013963 184.79 0.000 2.552902 2.607636 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ var(Residual) | .5355699 .0144511 .5079822 .564656 ------------------------------------------------------------------------------

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3040.178 2 6084.356 6089.72 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estimates store FitEmpty1P,

. . display as result "Ch 10b: Empty Means, Two-Level Model for the Variance for Positive Affect" Ch 10b: Empty Means, Two-Level Model for the Variance for Positive Affect

. display as result "Sessions Within Burst*Persons" Sessions Within Burst*Persons

. mixed posaff , /// > || personid: , noconstant variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1987.3615 Iteration 1: log likelihood = -1987.3615

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(0) = . Log likelihood = -1987.3615 Prob > chi2 = .

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 2.580643 .0296536 87.03 0.000 2.522523 2.638763 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: (empty) | -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3795157 .0267471 .330552 .4357323 -----------------------------+------------------------------------------------ var(Residual) | .1572839 .0046534 .1484227 .1666741 ------------------------------------------------------------------------------ LR test vs. linear regression: chibar2(01) = 2105.63 Prob >= chibar2 = 0.0000

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1987.361 3 3980.723 3988.769 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat wcorrelation, covariance,

Covariances for personid = 101 burst = 1:

obs | 1 2 3 -------------+------------------------ 1 | 0.537 2 | 0.380 0.537 3 | 0.380 0.380 0.537

. estat wcorrelation,

Standard deviations and correlations for personid = 101 burst = 1:

Standard deviations:

obs | 1 2 3 -------------+------------------------ sd | 0.733 0.733 0.733

Correlations:

obs | 1 2 3 -------------+------------------------ 1 | 1.000 2 | 0.707 1.000 3 | 0.707 0.707 1.000

. estimates store FitEmpty2P,

. . display as result "Eq 10b.5: Empty Means, Three-Level Model for the Variance for Positive Affect" Eq 10b.5: Empty Means, Three-Level Model for the Variance for Positive Affect

. display as result "Level-1 Sessions Within Level-2 Bursts Within Level-3 Persons" Level-1 Sessions Within Level-2 Bursts Within Level-3 Persons

. mixed posaff , /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1788.4815 Iteration 1: log likelihood = -1788.4815

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(0) = . Log likelihood = -1788.4815 Prob > chi2 = .

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _cons | 2.543132 .0562298 45.23 0.000 2.432923 2.65334 ------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | .3162942 .0466072 .2369536 .4222008 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .0643297 .0068973 .0521372 .0793736 -----------------------------+------------------------------------------------ var(Residual) | .1573514 .0046566 .1484843 .166748 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2503.39 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1788.481 4 3584.963 3595.692 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat icc,

Intraclass correlation

------------------------------------------------------------------------------ Level | ICC Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid | .5879344 .0370292 .5139623 .6581367 burst|personid | .7075119 .0262848 .6534823 .7562593 ------------------------------------------------------------------------------

. estat wcorrelation, covariance,

Covariances for personid = 101 burst = 1:

obs | 1 2 3 -------------+------------------------ 1 | 0.538 2 | 0.381 0.538 3 | 0.381 0.381 0.538

. estat wcorrelation,

Standard deviations and correlations for personid = 101 burst = 1:

Standard deviations:

obs | 1 2 3 -------------+------------------------ sd | 0.733 0.733 0.733

Correlations:

obs | 1 2 3 -------------+------------------------ 1 | 1.000 2 | 0.708 1.000 3 | 0.708 0.708 1.000

. estimates store FitEmpty3P,

. lrtest FitEmpty3P FitEmpty2P,

Likelihood-ratio test LR chi2(1) = 397.76 (Assumption: FitEmpty2P nested in FitEmpty3P) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Eq 10b.6: Saturated Means for Burst by Session" Eq 10b.6: Saturated Means for Burst by Session

. display as result "Three-Level Model for the Variance for Symptoms" Three-Level Model for the Variance for Symptoms

. mixed symptoms i.session i.burst i.session#i.burst, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3692.3004 Iteration 1: log likelihood = -3692.3004

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(29) = 144.50 Log likelihood = -3692.3004 Prob > chi2 = 0.0000

------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] --------------+---------------------------------------------------------------- session | 2 | -.2392776 .10628 -2.25 0.024 -.4475826 -.0309726 3 | -.1194769 .1067581 -1.12 0.263 -.3287189 .089765 4 | -.2734587 .1067867 -2.56 0.010 -.4827568 -.0641606 5 | -.2433253 .1064678 -2.29 0.022 -.4519983 -.0346522 6 | -.2812388 .1071716 -2.62 0.009 -.4912912 -.0711864 | burst | 2 | .4505038 .1401462 3.21 0.001 .1758223 .7251854 3 | .8033019 .1411198 5.69 0.000 .5267121 1.079892 4 | .4643568 .1444304 3.22 0.001 .1812785 .7474351 5 | .4601041 .1499751 3.07 0.002 .1661582 .7540499 | session#burst | 2 2 | -.0523891 .154464 -0.34 0.734 -.355133 .2503549 2 3 | -.0405616 .155656 -0.26 0.794 -.3456418 .2645186 2 4 | .0438753 .1586153 0.28 0.782 -.2670051 .3547557 2 5 | -.0204627 .1641928 -0.12 0.901 -.3422746 .3013493 3 2 | -.1824237 .1550723 -1.18 0.239 -.4863598 .1215125 3 3 | -.2678891 .1559832 -1.72 0.086 -.5736106 .0378324 3 4 | -.159026 .1592304 -1.00 0.318 -.4711118 .1530599 3 5 | -.0233802 .1645026 -0.14 0.887 -.3457994 .299039 4 2 | -.0915998 .155092 -0.59 0.555 -.3955744 .2123749 4 3 | -.264445 .1560026 -1.70 0.090 -.5702045 .0413145 4 4 | .1010449 .1589553 0.64 0.525 -.2105017 .4125916 4 5 | .0916405 .1645212 0.56 0.578 -.2308151 .4140961 5 2 | -.0585753 .1548726 -0.38 0.705 -.36212 .2449694 5 3 | -.412858 .1557845 -2.65 0.008 -.71819 -.1075259 5 4 | -.044031 .1587412 -0.28 0.781 -.3551581 .2670961 5 5 | .0744941 .1643144 0.45 0.650 -.2475562 .3965444 6 2 | -.094346 .1553572 -0.61 0.544 -.3988405 .2101485 6 3 | -.4072025 .1562665 -2.61 0.009 -.7134792 -.1009258 6 4 | -.2360026 .1592141 -1.48 0.138 -.5480565 .0760513 6 5 | .0214985 .1647713 0.13 0.896 -.3014472 .3444443 | _cons | 1.563352 .1394475 11.21 0.000 1.29004 1.836664 -------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | 1.109327 .1718238 .8188738 1.502804 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3739481 .0360546 .3095578 .4517321 -----------------------------+------------------------------------------------ var(Residual) | .6030572 .0178252 .5691132 .6390258 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2309.11 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3692.3 33 7450.601 7539.111 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. contrast i.session,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------ | df chi2 P>chi2 -------------+---------------------------------- symptoms | session | 5 76.76 0.0000 ------------------------------------------------

. margins i.session,

Predictive margins Number of obs = 2752

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- session | 1 | 1.985311 .1121307 17.71 0.000 1.765539 2.205083 2 | 1.731776 .11213 15.44 0.000 1.512006 1.951547 3 | 1.739471 .1121876 15.51 0.000 1.519588 1.959355 4 | 1.673612 .1121883 14.92 0.000 1.453727 1.893497 5 | 1.650119 .1121586 14.71 0.000 1.430292 1.869946 6 | 1.560679 .1122029 13.91 0.000 1.340766 1.780593 ------------------------------------------------------------------------------

. contrast i.burst,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------ | df chi2 P>chi2 -------------+---------------------------------- symptoms | burst | 4 39.10 0.0000 ------------------------------------------------

. margins i.burst,

Predictive margins Number of obs = 2752

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- burst | 1 | 1.370632 .1211829 11.31 0.000 1.133118 1.608146 2 | 1.741385 .1245648 13.98 0.000 1.497243 1.985528 3 | 1.942163 .1252773 15.50 0.000 1.696624 2.187702 4 | 1.786212 .1271938 14.04 0.000 1.536917 2.035508 5 | 1.854672 .1305979 14.20 0.000 1.598705 2.110639 ------------------------------------------------------------------------------

. contrast i.session#i.burst,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- symptoms | session#burst | 20 26.44 0.1518 -------------------------------------------------

. margins i.session#i.burst,

Adjusted predictions Number of obs = 2752

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------- | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] --------------+---------------------------------------------------------------- session#burst | 1 1 | 1.563352 .1394475 11.21 0.000 1.29004 1.836664 1 2 | 2.013856 .1439962 13.99 0.000 1.731628 2.296083 1 3 | 2.366654 .1449415 16.33 0.000 2.082573 2.650734 1 4 | 2.027708 .1481624 13.69 0.000 1.737316 2.318101 1 5 | 2.023456 .1535656 13.18 0.000 1.722473 2.324439 2 1 | 1.324074 .1389888 9.53 0.000 1.051661 1.596487 2 2 | 1.722189 .1439962 11.96 0.000 1.439962 2.004416 2 3 | 2.086814 .1452938 14.36 0.000 1.802044 2.371585 2 4 | 1.832306 .1481624 12.37 0.000 1.541913 2.122699 2 5 | 1.763715 .1535656 11.49 0.000 1.462732 2.064698 3 1 | 1.443875 .1394419 10.35 0.000 1.170574 1.717176 3 2 | 1.711955 .1442963 11.86 0.000 1.429139 1.99477 3 3 | 1.979288 .1452938 13.62 0.000 1.694517 2.264058 3 4 | 1.749206 .1484779 11.78 0.000 1.458194 2.040217 3 5 | 1.880599 .1535656 12.25 0.000 1.579616 2.181582 4 1 | 1.289893 .139446 9.25 0.000 1.016584 1.563202 4 2 | 1.648797 .1442963 11.43 0.000 1.365981 1.931613 4 3 | 1.82875 .1452938 12.59 0.000 1.543979 2.11352 4 4 | 1.855295 .1481624 12.52 0.000 1.564902 2.145688 4 5 | 1.841638 .1535656 11.99 0.000 1.540655 2.142621 5 1 | 1.320026 .1392205 9.48 0.000 1.047159 1.592894 5 2 | 1.711955 .1442963 11.86 0.000 1.429139 1.99477 5 3 | 1.71047 .1452938 11.77 0.000 1.4257 1.995241 5 4 | 1.740352 .1481624 11.75 0.000 1.449959 2.030745 5 5 | 1.854625 .1535656 12.08 0.000 1.553642 2.155608 6 1 | 1.282113 .1396659 9.18 0.000 1.008373 1.555853 6 2 | 1.638271 .1442963 11.35 0.000 1.355455 1.921086 6 3 | 1.678212 .1452938 11.55 0.000 1.393442 1.962983 6 4 | 1.510467 .1481624 10.19 0.000 1.220074 1.80086 6 5 | 1.763715 .1535656 11.49 0.000 1.462732 2.064698 -------------------------------------------------------------------------------

. margins i.session@i.burst,

Contrasts of adjusted predictions

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- session@burst | 1 | 5 10.79 0.0558 2 | 5 15.14 0.0098 3 | 5 52.39 0.0000 4 | 5 20.88 0.0009 5 | 5 5.86 0.3203 Joint | 25 105.05 0.0000 -------------------------------------------------

. margins i.burst@i.session,

Contrasts of adjusted predictions

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- burst@session | 1 | 4 33.08 0.0000 2 | 4 30.70 0.0000 3 | 4 16.27 0.0027 4 | 4 22.92 0.0001 5 | 4 16.22 0.0027 6 | 4 13.46 0.0092 Joint | 24 65.68 0.0000 -------------------------------------------------

. estimates store FitSatAllS,

. . display as result "Eq 10b.7: Piecewise Session Slopes by Observed Burst" Eq 10b.7: Piecewise Session Slopes by Observed Burst

. display as result "Three-Level Model for the Variance for Symptoms" Three-Level Model for the Variance for Symptoms

. mixed symptoms c.slope12 c.slope26 i.burst /// > c.slope12#i.burst c.slope26#i.burst, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3697.037 Iteration 1: log likelihood = -3697.037

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(14) = 134.62 Log likelihood = -3697.037 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------+---------------------------------------------------------------- slope12 | -.1903575 .0954842 -1.99 0.046 -.3775031 -.0032119 slope26 | -.020531 .0238719 -0.86 0.390 -.0673191 .026257 | burst | 2 | .3474688 .1218054 2.85 0.004 .1087346 .586203 3 | .7011409 .1229286 5.70 0.000 .4602052 .9420766 4 | .4955777 .1256592 3.94 0.000 .2492901 .7418653 5 | .4533517 .1305669 3.47 0.001 .1974452 .7092581 | burst#c.slope12 | 2 | -.1032867 .1386682 -0.74 0.456 -.3750714 .168498 3 | -.1024103 .1396409 -0.73 0.463 -.3761015 .1712808 4 | .0309676 .1423685 0.22 0.828 -.2480695 .3100047 5 | -.0070451 .1473099 -0.05 0.962 -.2957672 .281677 | burst#c.slope26 | 2 | .0037424 .0347195 0.11 0.914 -.0643067 .0717915 3 | -.0880711 .0349428 -2.52 0.012 -.1565578 -.0195844 4 | -.0447939 .0355927 -1.26 0.208 -.1145542 .0249664 5 | .0179336 .036828 0.49 0.626 -.0542479 .0901152 | _cons | 1.372849 .1308805 10.49 0.000 1.116328 1.62937 ---------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | 1.109782 .1719018 .8191982 1.50344 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3734815 .0360523 .3091024 .4512694 -----------------------------+------------------------------------------------ var(Residual) | .6055556 .017899 .5714711 .6416731 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2302.67 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3697.037 18 7430.074 7478.352 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. * Session 2 at Burst 1 . lincom _cons*1 + i1.burst

( 1) [symptoms]1b.burst + [symptoms]_cons = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 1.372849 .1308805 10.49 0.000 1.116328 1.62937 ------------------------------------------------------------------------------

. * Session 2 at Burst 2 . lincom _cons*1 + i2.burst

( 1) [symptoms]2.burst + [symptoms]_cons = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 1.720318 .1351155 12.73 0.000 1.455496 1.985139 ------------------------------------------------------------------------------

. * Session 2 at Burst 3 . lincom _cons*1 + i3.burst

( 1) [symptoms]3.burst + [symptoms]_cons = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.07399 .136132 15.24 0.000 1.807176 2.340804 ------------------------------------------------------------------------------

. * Session 2 at Burst 4 . lincom _cons*1 + i4.burst

( 1) [symptoms]4.burst + [symptoms]_cons = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 1.868427 .1386015 13.48 0.000 1.596773 2.140081 ------------------------------------------------------------------------------

. * Session 2 at Burst 5 . lincom _cons*1 + i5.burst

( 1) [symptoms]5.burst + [symptoms]_cons = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 1.826201 .1430637 12.76 0.000 1.545801 2.1066 ------------------------------------------------------------------------------

. * Slope12 at Burst 1 . lincom c.slope12*1 + c.slope12#i1.burst

( 1) [symptoms]slope12 + [symptoms]1b.burst#co.slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1903575 .0954842 -1.99 0.046 -.3775031 -.0032119 ------------------------------------------------------------------------------

. * Slope12 at Burst 2 . lincom c.slope12*1 + c.slope12#i2.burst

( 1) [symptoms]slope12 + [symptoms]2.burst#c.slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2936442 .1005567 -2.92 0.003 -.4907316 -.0965567 ------------------------------------------------------------------------------

. * Slope12 at Burst 3 . lincom c.slope12*1 + c.slope12#i3.burst

( 1) [symptoms]slope12 + [symptoms]3.burst#c.slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2927678 .1018943 -2.87 0.004 -.492477 -.0930587 ------------------------------------------------------------------------------

. * Slope12 at Burst 4 . lincom c.slope12*1 + c.slope12#i4.burst

( 1) [symptoms]slope12 + [symptoms]4.burst#c.slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1593899 .1056009 -1.51 0.131 -.3663639 .0475842 ------------------------------------------------------------------------------

. * Slope12 at Burst 5 . lincom c.slope12*1 + c.slope12#i5.burst

( 1) [symptoms]slope12 + [symptoms]5.burst#c.slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1974026 .1121739 -1.76 0.078 -.4172593 .0224541 ------------------------------------------------------------------------------

. * Slope26 at Burst 1 . lincom c.slope26*1 + c.slope26#i1.burst

( 1) [symptoms]slope26 + [symptoms]1b.burst#co.slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.020531 .0238719 -0.86 0.390 -.0673191 .026257 ------------------------------------------------------------------------------

. * Slope26 at Burst 2 . lincom c.slope26*1 + c.slope26#i2.burst

( 1) [symptoms]slope26 + [symptoms]2.burst#c.slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0167886 .0252107 -0.67 0.505 -.0662008 .0326235 ------------------------------------------------------------------------------

. * Slope26 at Burst 3 . lincom c.slope26*1 + c.slope26#i3.burst

( 1) [symptoms]slope26 + [symptoms]3.burst#c.slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1086022 .0255173 -4.26 0.000 -.1586152 -.0585891 ------------------------------------------------------------------------------

. * Slope26 at Burst 4 . lincom c.slope26*1 + c.slope26#i4.burst

( 1) [symptoms]slope26 + [symptoms]4.burst#c.slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0653249 .0264002 -2.47 0.013 -.1170685 -.0135814 ------------------------------------------------------------------------------

. * Slope26 at Burst 5 . lincom c.slope26*1 + c.slope26#i5.burst

( 1) [symptoms]slope26 + [symptoms]5.burst#c.slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0025974 .0280435 -0.09 0.926 -.0575616 .0523668 ------------------------------------------------------------------------------

. estimates store FitPiecebyBurstMeansS,

. . display as result "Eq 10b.8: Piecewise Session Slopes by Quadratic Burst" Eq 10b.8: Piecewise Session Slopes by Quadratic Burst

. display as result "Three-Level Model for the Variance for Symptoms" Three-Level Model for the Variance for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope12#c.burst1 c.slope26#c.burst1 /// > c.slope12#c.burst1#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3702.5302 Iteration 1: log likelihood = -3702.5302

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(8) = 122.88 Log likelihood = -3702.5302 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .4928563 .0988198 4.99 0.000 .299173 .6865395 | c.burst1#c.burst1 | -.0970135 .0243349 -3.99 0.000 -.144709 -.049318 | slope12 | -.2096013 .0906799 -2.31 0.021 -.3873307 -.0318719 slope26 | -.0058096 .0226752 -0.26 0.798 -.0502522 .038633 | c.slope12#c.burst1 | -.0701371 .1119713 -0.63 0.531 -.2895968 .1493226 | c.slope26#c.burst1 | -.0712009 .0280099 -2.54 0.011 -.1260993 -.0163024 | c.slope12#c.burst1#c.burst1 | .0206203 .0275953 0.75 0.455 -.0334656 .0747061 | c.slope26#c.burst1#c.burst1 | .0174983 .006904 2.53 0.011 .0039667 .03103 | _cons | 1.36775 .1284077 10.65 0.000 1.116075 1.619424 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | 1.106977 .1716897 .8168064 1.500231 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3791913 .0365095 .3139803 .457946 -----------------------------+------------------------------------------------ var(Residual) | .6073158 .0179517 .5731309 .6435397 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2300.32 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3702.53 12 7429.06 7461.246 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. * Slope12 at Burst 1 . lincom c.slope12*1 + c.slope12#c.burst1*0 + c.slope12#c.burst1#c.burst1*0

( 1) [symptoms]slope12 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2096013 .0906799 -2.31 0.021 -.3873307 -.0318719 ------------------------------------------------------------------------------

. * Slope12 at Burst 2 . lincom c.slope12*1 + c.slope12#c.burst1*1 + c.slope12#c.burst1#c.burst1*1

( 1) [symptoms]slope12 + [symptoms]c.slope12#c.burst1 + [symptoms]c.slope12#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2591182 .0617355 -4.20 0.000 -.3801175 -.1381188 ------------------------------------------------------------------------------

. * Slope12 at Burst 3 . lincom c.slope12*1 + c.slope12#c.burst1*2 + c.slope12#c.burst1#c.burst1*4

( 1) [symptoms]slope12 + 2*[symptoms]c.slope12#c.burst1 + 4*[symptoms]c.slope12#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2673945 .0715055 -3.74 0.000 -.4075428 -.1272462 ------------------------------------------------------------------------------

. * Slope12 at Burst 4 . lincom c.slope12*1 + c.slope12#c.burst1*3 + c.slope12#c.burst1#c.burst1*9

( 1) [symptoms]slope12 + 3*[symptoms]c.slope12#c.burst1 + 9*[symptoms]c.slope12#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2344303 .0639159 -3.67 0.000 -.359703 -.1091575 ------------------------------------------------------------------------------

. * Slope12 at Burst 5 . lincom c.slope12*1 + c.slope12#c.burst1*4 + c.slope12#c.burst1#c.burst1*16

( 1) [symptoms]slope12 + 4*[symptoms]c.slope12#c.burst1 + 16*[symptoms]c.slope12#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1602255 .1046946 -1.53 0.126 -.3654232 .0449722 ------------------------------------------------------------------------------

. * Slope26 at Burst 1 . lincom c.slope26*1 + c.slope26#c.burst1*0 + c.slope26#c.burst1#c.burst1*0

( 1) [symptoms]slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0058096 .0226752 -0.26 0.798 -.0502522 .038633 ------------------------------------------------------------------------------

. * Slope26 at Burst 2 . lincom c.slope26*1 + c.slope26#c.burst1*1 + c.slope26#c.burst1#c.burst1*1

( 1) [symptoms]slope26 + [symptoms]c.slope26#c.burst1 + [symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0595122 .0154592 -3.85 0.000 -.0898117 -.0292127 ------------------------------------------------------------------------------

. * Slope26 at Burst 3 . lincom c.slope26*1 + c.slope26#c.burst1*2 + c.slope26#c.burst1#c.burst1*4

( 1) [symptoms]slope26 + 2*[symptoms]c.slope26#c.burst1 + 4*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.078218 .0179044 -4.37 0.000 -.1133099 -.0431261 ------------------------------------------------------------------------------

. * Slope26 at Burst 4 . lincom c.slope26*1 + c.slope26#c.burst1*3 + c.slope26#c.burst1#c.burst1*9

( 1) [symptoms]slope26 + 3*[symptoms]c.slope26#c.burst1 + 9*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0619272 .0159908 -3.87 0.000 -.0932685 -.0305859 ------------------------------------------------------------------------------

. * Slope26 at Burst 5 . lincom c.slope26*1 + c.slope26#c.burst1*4 + c.slope26#c.burst1#c.burst1*16

( 1) [symptoms]slope26 + 4*[symptoms]c.slope26#c.burst1 + 16*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0106397 .026176 -0.41 0.684 -.0619438 .0406644 ------------------------------------------------------------------------------

. estimates store FitPiecebyQuadBurstS,

. lrtest FitPiecebyBurstMeansS FitPiecebyQuadBurstS,

Likelihood-ratio test LR chi2(6) = 10.99 (Assumption: FitPiecebyQu~S nested in FitPiecebyBu~S) Prob > chi2 = 0.0888

. . display as result "Eq 10b.9: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Eq 10b.9: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Three-Level Model for the Variance for Symptoms" Three-Level Model for the Variance for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3702.8547 Iteration 1: log likelihood = -3702.8547

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 122.21 Log likelihood = -3702.8547 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5192184 .0894733 5.80 0.000 .343854 .6945828 | c.burst1#c.burst1 | -.1047624 .0220219 -4.76 0.000 -.1479245 -.0616003 | slope12 | -.2280933 .0460023 -4.96 0.000 -.3182562 -.1379305 slope26 | -.00351 .0204896 -0.17 0.864 -.043669 .0366489 | c.slope26#c.burst1 | -.079968 .0242784 -3.29 0.001 -.1275528 -.0323833 | c.slope26#c.burst1#c.burst1 | .0200767 .0059822 3.36 0.001 .0083517 .0318016 | _cons | 1.360861 .1250753 10.88 0.000 1.115718 1.606004 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | 1.107072 .1717053 .8168751 1.500362 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3792306 .0365165 .3140077 .4580009 -----------------------------+------------------------------------------------ var(Residual) | .6074726 .0179565 .5732785 .6437061 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2299.95 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3702.855 10 7425.709 7452.531 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. * Slope26 at Burst 1 . lincom c.slope26*1 + c.slope26#c.burst1*0 + c.slope26#c.burst1#c.burst1*0

( 1) [symptoms]slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.00351 .0204896 -0.17 0.864 -.043669 .0366489 ------------------------------------------------------------------------------

. * Slope26 at Burst 2 . lincom c.slope26*1 + c.slope26#c.burst1*1 + c.slope26#c.burst1#c.burst1*1

( 1) [symptoms]slope26 + [symptoms]c.slope26#c.burst1 + [symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0634014 .0145768 -4.35 0.000 -.0919714 -.0348314 ------------------------------------------------------------------------------

. * Slope26 at Burst 3 . lincom c.slope26*1 + c.slope26#c.burst1*2 + c.slope26#c.burst1#c.burst1*4

( 1) [symptoms]slope26 + 2*[symptoms]c.slope26#c.burst1 + 4*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0831395 .0165427 -5.03 0.000 -.1155625 -.0507164 ------------------------------------------------------------------------------

. * Slope26 at Burst 4 . lincom c.slope26*1 + c.slope26#c.burst1*3 + c.slope26#c.burst1#c.burst1*9

( 1) [symptoms]slope26 + 3*[symptoms]c.slope26#c.burst1 + 9*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0627242 .0149999 -4.18 0.000 -.0921236 -.0333249 ------------------------------------------------------------------------------

. * Slope26 at Burst 5 . lincom c.slope26*1 + c.slope26#c.burst1*4 + c.slope26#c.burst1#c.burst1*16

( 1) [symptoms]slope26 + 4*[symptoms]c.slope26#c.burst1 + 16*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0021557 .0233887 -0.09 0.927 -.0479967 .0436853 ------------------------------------------------------------------------------

. estimates store FitPieceQuadBurst26S,

. lrtest FitPiecebyBurstMeansS FitPieceQuadBurst26S,

Likelihood-ratio test LR chi2(8) = 11.64 (Assumption: FitPieceQu~26S nested in FitPiecebyBu~S) Prob > chi2 = 0.1682

. lrtest FitSatAllS FitPieceQuadBurst26S,

Likelihood-ratio test LR chi2(23) = 21.11 (Assumption: FitPieceQu~26S nested in FitSatAllS) Prob > chi2 = 0.5745

. . display as result "Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Linear Burst Slope across Persons for Symptoms" Add Random Linear Burst Slope across Persons for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1, variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3699.5353 Iteration 1: log likelihood = -3699.4476 Iteration 2: log likelihood = -3699.4471 Iteration 3: log likelihood = -3699.4471

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 120.82 Log likelihood = -3699.4471 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5182214 .0881245 5.88 0.000 .3455005 .6909423 | c.burst1#c.burst1 | -.1033469 .0215518 -4.80 0.000 -.1455877 -.0611061 | slope12 | -.2278842 .0460016 -4.95 0.000 -.3180455 -.1377228 slope26 | -.0037004 .020489 -0.18 0.857 -.0438581 .0364574 | c.slope26#c.burst1 | -.0798012 .0242778 -3.29 0.001 -.1273849 -.0322176 | c.slope26#c.burst1#c.burst1 | .0200441 .0059821 3.35 0.001 .0083194 .0317687 | _cons | 1.359967 .1175118 11.57 0.000 1.129648 1.590286 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0124957 .0102588 .0025 .0624579 var(_cons) | .9360185 .1728257 .6518073 1.344156 cov(burst1,_cons) | .044102 .0322018 -.0190123 .1072163 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3490797 .0399419 .2789521 .4368372 -----------------------------+------------------------------------------------ var(Residual) | .6074532 .0179559 .5732603 .6436856 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(4) = 2306.77 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3699.447 12 7422.894 7455.08 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0124957 _cons | .044102 .9360185

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | .4077897 1

. estimates store FitRandBurstLin3S,

. lrtest FitRandBurstLin3S FitPieceQuadBurst26S,

Likelihood-ratio test LR chi2(2) = 6.82 (Assumption: FitPieceQu~26S nested in FitRandBurs~3S) Prob > chi2 = 0.0331

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Quadratic Burst Slope across Persons for Symptoms" Add Random Quadratic Burst Slope across Persons for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1 burst1sq, variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3698.6421 (not concave) Iteration 1: log likelihood = -3698.5451 (not concave) Iteration 2: log likelihood = -3698.2889 (not concave) Iteration 3: log likelihood = -3698.1659 Iteration 4: log likelihood = -3698.0564 (backed up) Iteration 5: log likelihood = -3698.0018 Iteration 6: log likelihood = -3698.0017

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 118.95 Log likelihood = -3698.0017 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5269017 .091979 5.73 0.000 .3466261 .7071773 | c.burst1#c.burst1 | -.106011 .0224261 -4.73 0.000 -.1499654 -.0620566 | slope12 | -.2275968 .0459993 -4.95 0.000 -.3177538 -.1374398 slope26 | -.0037946 .0204879 -0.19 0.853 -.0439501 .0363609 | c.slope26#c.burst1 | -.079671 .0242765 -3.28 0.001 -.127252 -.0320899 | c.slope26#c.burst1#c.burst1 | .0200137 .0059818 3.35 0.001 .0082896 .0317378 | _cons | 1.359554 .1139834 11.93 0.000 1.136151 1.582957 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .1104859 .1175527 .0137297 .8891022 var(burst1sq) | .005474 .0069282 .0004581 .0654077 var(_cons) | .8703938 .1776125 .5834715 1.29841 cov(burst1,burst1sq) | -.0229248 .0278112 -.0774338 .0315843 cov(burst1,_cons) | .1214871 .1050662 -.0844388 .327413 cov(burst1sq,_cons) | -.0230128 .025123 -.072253 .0262274 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .3238874 .0462246 .2448569 .428426 -----------------------------+------------------------------------------------ var(Residual) | .6073896 .0179532 .5732017 .6436165 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(7) = 2309.66 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3698.002 15 7426.003 7466.235 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 burst1sq _cons -------------+--------------------------------- burst1 | .1104859 burst1sq | -.0229248 .005474 _cons | .1214871 -.0230128 .8703938

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 burst1sq _cons -------------+--------------------------------- burst1 | 1 burst1sq | -.9321747 1 _cons | .3917588 -.3333933 1

. estimates store FitRandBurstQuad3S,

. lrtest FitRandBurstQuad3S FitRandBurstLin3S,

Likelihood-ratio test LR chi2(3) = 2.89 (Assumption: FitRandBurs~3S nested in FitRandBurs~3S) Prob > chi2 = 0.4088

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Linear Slope12 Across Bursts for Symptoms" Add Random Linear Slope12 Across Bursts for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1, variance mle covariance(unstructured) /// > || burst: slope12, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3690.1654 Iteration 1: log likelihood = -3689.7255 Iteration 2: log likelihood = -3689.7235 Iteration 3: log likelihood = -3689.7235

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 108.77 Log likelihood = -3689.7235 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5161885 .0874173 5.90 0.000 .3448537 .6875234 | c.burst1#c.burst1 | -.102869 .0213798 -4.81 0.000 -.1447727 -.0609654 | slope12 | -.2282787 .0501206 -4.55 0.000 -.3265133 -.1300441 slope26 | -.0041686 .0202552 -0.21 0.837 -.043868 .0355308 | c.slope26#c.burst1 | -.0780539 .0242595 -3.22 0.001 -.1256016 -.0305062 | c.slope26#c.burst1#c.burst1 | .0195277 .005978 3.27 0.001 .007811 .0312445 | _cons | 1.360315 .1173719 11.59 0.000 1.130271 1.59036 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0120151 .0102013 .0022752 .0634502 var(_cons) | .939182 .1731805 .6543234 1.348053 cov(burst1,_cons) | .0436477 .0321411 -.0193477 .1066431 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .2482196 .0653033 .1482165 .415696 var(_cons) | .3721178 .0426019 .2973244 .4657258 cov(slope12,_cons) | .0684791 .0372976 -.0046228 .141581 -----------------------------+------------------------------------------------ var(Residual) | .5661321 .0187067 .5306296 .6040098 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(6) = 2326.22 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3689.724 14 7407.447 7444.997 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0120151 _cons | .0436477 .939182

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | .4108875 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | .2482196 _cons | .0684791 .3721178

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | 1 _cons | .22532 1

. estimates store FitRandSlope12at2S,

. lrtest FitRandSlope12at2S FitRandBurstLin3S,

Likelihood-ratio test LR chi2(2) = 19.45 (Assumption: FitRandBurs~3S nested in FitRandSlop~2S) Prob > chi2 = 0.0001

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Linear Slope12 Across Persons for Symptoms" Add Random Linear Slope12 Across Persons for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1 slope12, variance mle covariance(unstructured) /// > || burst: slope12, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3688.5088 Iteration 1: log likelihood = -3687.0505 Iteration 2: log likelihood = -3686.9825 Iteration 3: log likelihood = -3686.9732 Iteration 4: log likelihood = -3686.9725 Iteration 5: log likelihood = -3686.9725

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 111.64 Log likelihood = -3686.9725 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5149366 .0871241 5.91 0.000 .3441765 .6856968 | c.burst1#c.burst1 | -.1024276 .0212925 -4.81 0.000 -.1441601 -.060695 | slope12 | -.2284078 .0537517 -4.25 0.000 -.3337591 -.1230565 slope26 | -.0044558 .0201869 -0.22 0.825 -.0440215 .0351099 | c.slope26#c.burst1 | -.0779484 .0241365 -3.23 0.001 -.1252551 -.0306416 | c.slope26#c.burst1#c.burst1 | .0195428 .0059476 3.29 0.001 .0078857 .0311999 | _cons | 1.361381 .1165319 11.68 0.000 1.132983 1.589779 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0125428 . . . var(slope12) | .0490724 . . . var(_cons) | .920561 . . . cov(burst1,slope12) | .0194093 . . . cov(burst1,_cons) | .0469846 . . . cov(slope12,_cons) | -.0463498 . . . -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .198475 . . . var(_cons) | .3708477 . . . cov(slope12,_cons) | .0634174 . . . -----------------------------+------------------------------------------------ var(Residual) | .5661444 . . . ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(9) = 2331.72 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3686.972 7 7387.945 7406.72 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | .0125428 slope12 | .0194093 .0490724 _cons | .0469846 -.0463498 .920561

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | 1 slope12 | .7823386 1 _cons | .4372534 -.2180735 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | .198475 _cons | .0634174 .3708477

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | 1 _cons | .2337534 1

. estimates store FitRandSlope12at23S,

. lrtest FitRandSlope12at23S FitRandSlope12at2S, force

Likelihood-ratio test LR chi2(7) = -5.50 (Assumption: FitRandSlo~23S nested in FitRandSlop~2S) Prob > chi2 = 1.0000

. . display as result "Eq 10b.10: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Eq 10b.10: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Linear Slope26 Across Bursts for Symptoms" Add Random Linear Slope26 Across Bursts for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1, variance mle covariance(unstructured) /// > || burst: slope12 slope26, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3679.983 Iteration 1: log likelihood = -3677.3207 Iteration 2: log likelihood = -3677.2405 Iteration 3: log likelihood = -3677.2402

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 96.58 Log likelihood = -3677.2402 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5190886 .0944081 5.50 0.000 .334052 .7041251 | c.burst1#c.burst1 | -.1036762 .023117 -4.48 0.000 -.1489847 -.0583677 | slope12 | -.226874 .0480213 -4.72 0.000 -.3209941 -.132754 slope26 | -.0048296 .022309 -0.22 0.829 -.0485544 .0388952 | c.slope26#c.burst1 | -.0778458 .027002 -2.88 0.004 -.1307688 -.0249229 | c.slope26#c.burst1#c.burst1 | .0194929 .0066559 2.93 0.003 .0064476 .0325381 | _cons | 1.359586 .1210293 11.23 0.000 1.122373 1.596799 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0123132 .0100391 .002491 .0608651 var(_cons) | .938353 .172137 .6549631 1.34436 cov(burst1,_cons) | .0431171 .0317323 -.0190771 .1053114 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .20098 .0772613 .0946088 .4269472 var(slope26) | .0119842 .0047983 .0054676 .0262675 var(_cons) | .512536 .0658087 .3985029 .6591999 cov(slope12,slope26) | .0089391 .0137867 -.0180824 .0359605 cov(slope12,_cons) | .0993057 .0529121 -.0044002 .2030116 cov(slope26,_cons) | -.0459361 .0144282 -.0742148 -.0176573 -----------------------------+------------------------------------------------ var(Residual) | .5362453 .0204725 .4975844 .5779101 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(9) = 2351.18 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3677.24 17 7388.48 7434.077 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0123132 _cons | .0431171 .938353

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | .4011268 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | .20098 slope26 | .0089391 .0119842 _cons | .0993057 -.0459361 .512536

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | 1 slope26 | .1821424 1 _cons | .3094108 -.5861217 1

. * Slope26 at Burst 1 . lincom c.slope26*1 + c.slope26#c.burst1*0 + c.slope26#c.burst1#c.burst1*0

( 1) [symptoms]slope26 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0048296 .022309 -0.22 0.829 -.0485544 .0388952 ------------------------------------------------------------------------------

. * Slope26 at Burst 2 . lincom c.slope26*1 + c.slope26#c.burst1*1 + c.slope26#c.burst1#c.burst1*1

( 1) [symptoms]slope26 + [symptoms]c.slope26#c.burst1 + [symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0631826 .0155575 -4.06 0.000 -.0936746 -.0326905 ------------------------------------------------------------------------------

. * Slope26 at Burst 3 . lincom c.slope26*1 + c.slope26#c.burst1*2 + c.slope26#c.burst1#c.burst1*4

( 1) [symptoms]slope26 + 2*[symptoms]c.slope26#c.burst1 + 4*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0825498 .0178286 -4.63 0.000 -.1174933 -.0476064 ------------------------------------------------------------------------------

. * Slope26 at Burst 4 . lincom c.slope26*1 + c.slope26#c.burst1*3 + c.slope26#c.burst1#c.burst1*9

( 1) [symptoms]slope26 + 3*[symptoms]c.slope26#c.burst1 + 9*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0629314 .0160508 -3.92 0.000 -.0943905 -.0314723 ------------------------------------------------------------------------------

. * Slope26 at Burst 5 . lincom c.slope26*1 + c.slope26#c.burst1*4 + c.slope26#c.burst1#c.burst1*16

( 1) [symptoms]slope26 + 4*[symptoms]c.slope26#c.burst1 + 16*[symptoms]c.slope26#c.burst1#c.burst1 = 0

------------------------------------------------------------------------------ symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0043272 .0256325 -0.17 0.866 -.0545659 .0459116 ------------------------------------------------------------------------------

. estimates store FitRandSlope26at2S,

. lrtest FitRandSlope26at2S FitRandSlope12at2S,

Likelihood-ratio test LR chi2(3) = 24.97 (Assumption: FitRandSlop~2S nested in FitRandSlop~2S) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. predict PredUncS, xb,

. margins, at (c.slope12=-1 c.slope26=0 c.burst1=(0(1)4)) vsquish,

Adjusted predictions Number of obs = 2752

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 0 slope12 = -1 slope26 = 0 2._at : burst1 = 1 slope12 = -1 slope26 = 0 3._at : burst1 = 2 slope12 = -1 slope26 = 0 4._at : burst1 = 3 slope12 = -1 slope26 = 0 5._at : burst1 = 4 slope12 = -1 slope26 = 0

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 1.58646 .1230454 12.89 0.000 1.345295 1.827624 2 | 2.001872 .1149095 17.42 0.000 1.776654 2.227091 3 | 2.209932 .124346 17.77 0.000 1.966219 2.453646 4 | 2.21064 .1277847 17.30 0.000 1.960186 2.461093 5 | 2.003995 .1518102 13.20 0.000 1.706452 2.301537 ------------------------------------------------------------------------------

. margins, at (c.slope12=0 c.slope26=(0(1)4) c.burst1=(0(1)4)) vsquish,

Adjusted predictions Number of obs = 2752

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 0 slope12 = 0 slope26 = 0 2._at : burst1 = 0 slope12 = 0 slope26 = 1 3._at : burst1 = 0 slope12 = 0 slope26 = 2 4._at : burst1 = 0 slope12 = 0 slope26 = 3 5._at : burst1 = 0 slope12 = 0 slope26 = 4 6._at : burst1 = 1 slope12 = 0 slope26 = 0 7._at : burst1 = 1 slope12 = 0 slope26 = 1 8._at : burst1 = 1 slope12 = 0 slope26 = 2 9._at : burst1 = 1 slope12 = 0 slope26 = 3 10._at : burst1 = 1 slope12 = 0 slope26 = 4 11._at : burst1 = 2 slope12 = 0 slope26 = 0 12._at : burst1 = 2 slope12 = 0 slope26 = 1 13._at : burst1 = 2 slope12 = 0 slope26 = 2 14._at : burst1 = 2 slope12 = 0 slope26 = 3 15._at : burst1 = 2 slope12 = 0 slope26 = 4 16._at : burst1 = 3 slope12 = 0 slope26 = 0 17._at : burst1 = 3 slope12 = 0 slope26 = 1 18._at : burst1 = 3 slope12 = 0 slope26 = 2 19._at : burst1 = 3 slope12 = 0 slope26 = 3 20._at : burst1 = 3 slope12 = 0 slope26 = 4 21._at : burst1 = 4 slope12 = 0 slope26 = 0 22._at : burst1 = 4 slope12 = 0 slope26 = 1 23._at : burst1 = 4 slope12 = 0 slope26 = 2 24._at : burst1 = 4 slope12 = 0 slope26 = 3 25._at : burst1 = 4 slope12 = 0 slope26 = 4

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 1.359586 .1210293 11.23 0.000 1.122373 1.596799 2 | 1.354756 .1142729 11.86 0.000 1.130785 1.578727 3 | 1.349927 .1116418 12.09 0.000 1.131113 1.56874 4 | 1.345097 .1134234 11.86 0.000 1.122791 1.567403 5 | 1.340267 .1194204 11.22 0.000 1.106208 1.574327 6 | 1.774998 .1128553 15.73 0.000 1.553806 1.99619 7 | 1.711816 .1091593 15.68 0.000 1.497867 1.925764 8 | 1.648633 .1076071 15.32 0.000 1.437727 1.859539 9 | 1.58545 .1082907 14.64 0.000 1.373205 1.797696 10 | 1.522268 .1111689 13.69 0.000 1.304381 1.740155 11 | 1.983058 .1225 16.19 0.000 1.742963 2.223154 12 | 1.900508 .1181252 16.09 0.000 1.668987 2.132029 13 | 1.817958 .1163468 15.63 0.000 1.589923 2.045994 14 | 1.735409 .1172831 14.80 0.000 1.505538 1.965279 15 | 1.652859 .120871 13.67 0.000 1.415956 1.889762 16 | 1.983766 .12599 15.75 0.000 1.73683 2.230701 17 | 1.920834 .1224784 15.68 0.000 1.680781 2.160888 18 | 1.857903 .1210113 15.35 0.000 1.620725 2.095081 19 | 1.794971 .1216624 14.75 0.000 1.556517 2.033425 20 | 1.73204 .1243987 13.92 0.000 1.488223 1.975857 21 | 1.777121 .1502634 11.83 0.000 1.48261 2.071631 22 | 1.772794 .1431498 12.38 0.000 1.492225 2.053362 23 | 1.768466 .1404233 12.59 0.000 1.493242 2.043691 24 | 1.764139 .1423362 12.39 0.000 1.485165 2.043113 25 | 1.759812 .1487095 11.83 0.000 1.468347 2.051277 ------------------------------------------------------------------------------

. corr symptoms PredUncS (obs=2752)

| symptoms PredUncS -------------+------------------ symptoms | 1.0000 PredUncS | 0.1583 1.0000



. . display as result "Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)" Ch 10b: Piecewise Session Slopes (Slope26 by Quadratic Burst Only)

. display as result "Add Random Linear Slope26 Across Persons for Symptoms" Add Random Linear Slope26 Across Persons for Symptoms

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1 slope26, variance mle covariance(unstructured) /// > || burst: slope12 slope26, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3680.0144 Iteration 1: log likelihood = -3676.4099 Iteration 2: log likelihood = -3676.3035 Iteration 3: log likelihood = -3676.303 Iteration 4: log likelihood = -3676.303

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.5 30 burst | 462 1 6.0 6 -----------------------------------------------------------

Wald chi2(6) = 99.45 Log likelihood = -3676.303 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5182707 .0936172 5.54 0.000 .3347843 .7017571 | c.burst1#c.burst1 | -.1033755 .0229132 -4.51 0.000 -.1482847 -.0584664 | slope12 | -.2270469 .048026 -4.73 0.000 -.3211762 -.1329177 slope26 | -.004931 .0223514 -0.22 0.825 -.0487389 .0388769 | c.slope26#c.burst1 | -.0779094 .0266366 -2.92 0.003 -.1301161 -.0257026 | c.slope26#c.burst1#c.burst1 | .0195081 .0065659 2.97 0.003 .0066392 .0323771 | _cons | 1.359681 .1223793 11.11 0.000 1.119822 1.59954 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0122386 .0100362 .002453 .06106 var(slope26) | .0016078 .0021105 .0001227 .0210672 var(_cons) | .9829422 .185155 .6794988 1.421894 cov(burst1,slope26) | .0027703 .002983 -.0030762 .0086169 cov(burst1,_cons) | .0381618 .0327078 -.0259444 .1022679 cov(slope26,_cons) | -.0134628 .0147446 -.0423616 .015436 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .2010762 .0772909 .0946609 .4271206 var(slope26) | .0106164 .0050532 .0041766 .0269856 var(_cons) | .5059069 .0656506 .392294 .6524233 cov(slope12,slope26) | .0074706 .013868 -.0197102 .0346515 cov(slope12,_cons) | .1053492 .0532018 .0010757 .2096228 cov(slope26,_cons) | -.0424978 .0146379 -.0711876 -.0138081 -----------------------------+------------------------------------------------ var(Residual) | .536319 .0204778 .4976482 .5779948 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(12) = 2353.06 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3676.303 20 7392.606 7446.249 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope26 _cons -------------+--------------------------------- burst1 | .0122386 slope26 | .0027703 .0016078 _cons | .0381618 -.0134628 .9829422

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope26 _cons -------------+--------------------------------- burst1 | 1 slope26 | .6245299 1 _cons | .3479354 -.3386557 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | .2010762 slope26 | .0074706 .0106164 _cons | .1053492 -.0424978 .5059069

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | 1 slope26 | .1616923 1 _cons | .3303054 -.5798866 1

. estimates store FitRandSlope26at23S,

. lrtest FitRandSlope26at23S FitRandSlope26at2S,

Likelihood-ratio test LR chi2(3) = 1.87 (Assumption: FitRandSlop~2S nested in FitRandSlo~23S) Prob > chi2 = 0.5989

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Final Unconditional Model for Symptoms" Ch 10b: Final Unconditional Model for Symptoms

. display as result "Remove Level-2 Random Effects Variances and Covariances" Remove Level-2 Random Effects Variances and Covariances

. mixed symptoms c.burst1 c.burst1#c.burst1 c.slope12 c.slope26 /// > c.slope26#c.burst1 c.slope26#c.burst1#c.burst1, /// > || personid: burst1, variance mle covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -3884.2212 Iteration 1: log likelihood = -3884.2212

Computing standard errors:

Mixed-effects ML regression Number of obs = 2752 Group variable: personid Number of groups = 108

Obs per group: min = 4 avg = 25.5 max = 30



Wald chi2(6) = 130.15 Log likelihood = -3884.2212 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------------------- symptoms | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------------------+---------------------------------------------------------------- burst1 | .5220526 .0677584 7.70 0.000 .3892485 .6548567 | c.burst1#c.burst1 | -.1028784 .0157865 -6.52 0.000 -.1338194 -.0719373 | slope12 | -.2293217 .0531987 -4.31 0.000 -.3335891 -.1250542 slope26 | -.0053104 .0236943 -0.22 0.823 -.0517505 .0411296 | c.slope26#c.burst1 | -.0789205 .0280769 -2.81 0.005 -.1339503 -.0238907 | c.slope26#c.burst1#c.burst1 | .0199375 .0069183 2.88 0.004 .0063779 .0334971 | _cons | 1.362601 .1171124 11.63 0.000 1.133065 1.592137 ---------------------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0551579 .0112188 .0370236 .0821747 var(_cons) | 1.160262 .1721284 .8675166 1.551795 cov(burst1,_cons) | -.0210214 .0326716 -.0850565 .0430137 -----------------------------+------------------------------------------------ var(Residual) | .8129323 .0228633 .7693338 .8590016 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(3) = 1937.22 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -3884.221 11 7790.442 7819.946 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0551579 _cons | -.0210214 1.160262

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | -.083096 1

. estimates store FitNo2S,

. lrtest FitRandSlope26at2S FitNo2S,

Likelihood-ratio test LR chi2(6) = 413.96 (Assumption: FitNo2S nested in FitRandSlop~2S) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Eq 10b.6: Saturated Means for Burst by Session" Eq 10b.6: Saturated Means for Burst by Session

. display as result "Three-Level Model for the Variance for Positive Affect" Three-Level Model for the Variance for Positive Affect

. mixed posaff i.session i.burst i.session#i.burst, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1742.7414 Iteration 1: log likelihood = -1742.7414

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(29) = 93.95 Log likelihood = -1742.7414 Prob > chi2 = 0.0000

------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] --------------+---------------------------------------------------------------- session | 2 | -.1646552 .0537188 -3.07 0.002 -.2699422 -.0593682 3 | -.2882953 .0539617 -5.34 0.000 -.3940582 -.1825324 4 | -.1864175 .0541293 -3.44 0.001 -.292509 -.080326 5 | -.2396754 .0538176 -4.45 0.000 -.3451559 -.1341949 6 | -.130029 .0543155 -2.39 0.017 -.2364854 -.0235725 | burst | 2 | -.0831215 .0650971 -1.28 0.202 -.2107096 .0444666 3 | -.3306387 .0655381 -5.04 0.000 -.4590911 -.2021864 4 | -.3275894 .0670465 -4.89 0.000 -.4589982 -.1961807 5 | -.408072 .0695754 -5.87 0.000 -.5444373 -.2717067 | session#burst | 2 2 | .0188219 .0779666 0.24 0.809 -.1339899 .1716336 2 3 | .1298707 .0785547 1.65 0.098 -.0240936 .2838351 2 4 | .1048851 .0800569 1.31 0.190 -.0520236 .2617938 2 5 | .16985 .0828655 2.05 0.040 .0074365 .3322635 3 2 | .1411002 .0782728 1.80 0.071 -.0123116 .294512 3 3 | .262113 .0787212 3.33 0.001 .1078223 .4164037 3 4 | .2569171 .0803662 3.20 0.001 .0994023 .4144319 3 5 | .3142694 .0830232 3.79 0.000 .151547 .4769917 4 2 | .0750118 .0783884 0.96 0.339 -.0786266 .2286503 4 3 | .2204502 .0788361 2.80 0.005 .0659344 .374966 4 4 | .2231991 .0803329 2.78 0.005 .0657495 .3806488 4 5 | .2435604 .0831322 2.93 0.003 .0806242 .4064965 5 2 | .0777434 .0781735 0.99 0.320 -.0754738 .2309606 5 3 | .3139876 .0787524 3.99 0.000 .1596358 .4683395 5 4 | .2557673 .0801232 3.19 0.001 .0987287 .412806 5 5 | .3461689 .0829296 4.17 0.000 .1836299 .5087079 6 2 | .0523075 .0785172 0.67 0.505 -.1015834 .2061984 6 3 | .209223 .0789641 2.65 0.008 .0544561 .3639899 6 4 | .1208336 .0804585 1.50 0.133 -.0368623 .2785294 6 5 | .175488 .0834331 2.10 0.035 .0119622 .3390138 | _cons | 2.801692 .0707759 39.59 0.000 2.662974 2.94041 -------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | .3258367 .0477945 .2444239 .4343665 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .0567707 .006275 .0457128 .0705034 -----------------------------+------------------------------------------------ var(Residual) | .1532679 .0045349 .1446324 .1624189 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2552.57 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1742.741 33 3551.483 3639.993 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. contrast i.session,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------ | df chi2 P>chi2 -------------+---------------------------------- posaff | session | 5 19.00 0.0019 ------------------------------------------------

. margins i.session,

Predictive margins Number of obs = 2747

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- session | 1 | 2.586608 .0592399 43.66 0.000 2.4705 2.702716 2 | 2.500649 .0592328 42.22 0.000 2.384555 2.616743 3 | 2.482404 .0592596 41.89 0.000 2.366258 2.598551 4 | 2.543796 .059275 42.92 0.000 2.427619 2.659973 5 | 2.533504 .0592529 42.76 0.000 2.417371 2.649638 6 | 2.562338 .0592847 43.22 0.000 2.446142 2.678534 ------------------------------------------------------------------------------

. contrast i.burst,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------ | df chi2 P>chi2 -------------+---------------------------------- posaff | burst | 4 33.82 0.0000 ------------------------------------------------

. margins i.burst,

Predictive margins Number of obs = 2747

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- burst | 1 | 2.633587 .0615269 42.80 0.000 2.512997 2.754178 2 | 2.611203 .0627243 41.63 0.000 2.488266 2.734141 3 | 2.492029 .0629856 39.57 0.000 2.36858 2.615479 4 | 2.466131 .0636433 38.75 0.000 2.341392 2.59087 5 | 2.433605 .0648439 37.53 0.000 2.306513 2.560696 ------------------------------------------------------------------------------

. contrast i.session#i.burst,

Contrasts of marginal linear predictions

Margins : asbalanced

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- posaff | session#burst | 20 38.12 0.0086 -------------------------------------------------

. margins i.session#i.burst,

Adjusted predictions Number of obs = 2747

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------------------------------------- | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] --------------+---------------------------------------------------------------- session#burst | 1 1 | 2.801692 .0707759 39.59 0.000 2.662974 2.94041 1 2 | 2.718571 .0725332 37.48 0.000 2.576408 2.860733 1 3 | 2.471053 .0729272 33.88 0.000 2.328119 2.613988 1 4 | 2.474103 .0742826 33.31 0.000 2.328512 2.619694 1 5 | 2.39362 .0765679 31.26 0.000 2.24355 2.543691 2 1 | 2.637037 .0704401 37.44 0.000 2.498977 2.775097 2 2 | 2.572737 .0725332 35.47 0.000 2.430575 2.7149 2 3 | 2.436269 .0730923 33.33 0.000 2.293011 2.579527 2 4 | 2.414333 .0742826 32.50 0.000 2.268742 2.559924 2 5 | 2.398815 .0765679 31.33 0.000 2.248745 2.548885 3 1 | 2.513397 .0706623 35.57 0.000 2.374901 2.651892 3 2 | 2.571376 .0726778 35.38 0.000 2.42893 2.713822 3 3 | 2.444871 .0730923 33.45 0.000 2.301613 2.58813 3 4 | 2.442725 .0744403 32.81 0.000 2.296824 2.588625 3 5 | 2.419594 .0765679 31.60 0.000 2.269524 2.569665 4 1 | 2.615275 .0707824 36.95 0.000 2.476544 2.754006 4 2 | 2.607165 .0726778 35.87 0.000 2.464719 2.749611 4 3 | 2.505086 .0730923 34.27 0.000 2.361828 2.648345 4 4 | 2.510884 .0742826 33.80 0.000 2.365293 2.656476 4 5 | 2.450763 .0765679 32.01 0.000 2.300693 2.600833 5 1 | 2.562017 .0705529 36.31 0.000 2.423736 2.700298 5 2 | 2.556639 .0726778 35.18 0.000 2.414193 2.699085 5 3 | 2.545366 .0732323 34.76 0.000 2.401833 2.688898 5 4 | 2.490195 .0742826 33.52 0.000 2.344604 2.635786 5 5 | 2.500114 .0765679 32.65 0.000 2.350043 2.650184 6 1 | 2.671663 .0708913 37.69 0.000 2.532719 2.810608 6 2 | 2.640849 .0726778 36.34 0.000 2.498403 2.783295 6 3 | 2.550248 .0730923 34.89 0.000 2.406989 2.693506 6 4 | 2.464907 .0742826 33.18 0.000 2.319316 2.610499 6 5 | 2.439079 .0767632 31.77 0.000 2.288626 2.589532 -------------------------------------------------------------------------------

. margins i.session@i.burst,

Contrasts of adjusted predictions

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- session@burst | 1 | 5 34.08 0.0000 2 | 5 11.52 0.0419 3 | 5 7.37 0.1946 4 | 5 3.33 0.6489 5 | 5 3.89 0.5646 Joint | 25 60.20 0.0001 -------------------------------------------------

. margins i.burst@i.session,

Contrasts of adjusted predictions

Expression : Linear prediction, fixed portion, predict()

------------------------------------------------- | df chi2 P>chi2 --------------+---------------------------------- burst@session | 1 | 4 54.63 0.0000 2 | 4 20.12 0.0005 3 | 4 6.66 0.1550 4 | 4 8.47 0.0759 5 | 4 1.86 0.7612 6 | 4 17.80 0.0014 Joint | 24 71.98 0.0000 -------------------------------------------------

. estimates store FitSatAllP,

. . display as result "Eq 10b.7: Piecewise Session Slopes by Observed Burst" Eq 10b.7: Piecewise Session Slopes by Observed Burst

. display as result "Three-Level Model for the Variance for Positive Affect" Three-Level Model for the Variance for Positive Affect

. mixed posaff c.slope12 c.slope26 i.burst /// > c.slope12#i.burst c.slope26#i.burst, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1750.7182 Iteration 1: log likelihood = -1750.7182

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(14) = 77.64 Log likelihood = -1750.7182 Prob > chi2 = 0.0000

--------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ----------------+---------------------------------------------------------------- slope12 | -.2245959 .0483801 -4.64 0.000 -.3194192 -.1297726 slope26 | .011249 .0120779 0.93 0.352 -.0124233 .0349212 | burst | 2 | -.011982 .0548121 -0.22 0.827 -.1194117 .0954477 3 | -.1468239 .0553261 -2.65 0.008 -.2552611 -.0383866 4 | -.1425882 .0565245 -2.52 0.012 -.2533742 -.0318021 5 | -.1681563 .0587066 -2.86 0.004 -.283219 -.0530936 | burst#c.slope12 | 2 | .0715265 .0701297 1.02 0.308 -.0659252 .2089781 3 | .184226 .0706054 2.61 0.009 .045842 .3226101 4 | .1854155 .0719935 2.58 0.010 .0443108 .3265202 5 | .2403342 .0744929 3.23 0.001 .0943308 .3863376 | burst#c.slope26 | 2 | .0008844 .0175455 0.05 0.960 -.0335041 .0352729 3 | .021576 .017665 1.22 0.222 -.0130467 .0561987 4 | .0036036 .0179869 0.20 0.841 -.03165 .0388572 5 | .0049608 .0186422 0.27 0.790 -.0315773 .0414989 | _cons | 2.577305 .0663925 38.82 0.000 2.447178 2.707432 ---------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | .3259172 .0478093 .2444799 .4344815 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .0565401 .0062715 .0454925 .0702706 -----------------------------+------------------------------------------------ var(Residual) | .1543539 .004567 .1456574 .1635696 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2540.87 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1750.718 18 3537.436 3585.715 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. * Session 2 at Burst 1 . lincom _cons*1 + i1.burst

( 1) [posaff]1b.burst + [posaff]_cons = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.577305 .0663925 38.82 0.000 2.447178 2.707432 ------------------------------------------------------------------------------

. * Session 2 at Burst 2 . lincom _cons*1 + i2.burst

( 1) [posaff]2.burst + [posaff]_cons = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.565323 .0680606 37.69 0.000 2.431927 2.698719 ------------------------------------------------------------------------------

. * Session 2 at Burst 3 . lincom _cons*1 + i3.burst

( 1) [posaff]3.burst + [posaff]_cons = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.430481 .068473 35.50 0.000 2.296277 2.564686 ------------------------------------------------------------------------------

. * Session 2 at Burst 4 . lincom _cons*1 + i4.burst

( 1) [posaff]4.burst + [posaff]_cons = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.434717 .0694442 35.06 0.000 2.298609 2.570825 ------------------------------------------------------------------------------

. * Session 2 at Burst 5 . lincom _cons*1 + i5.burst

( 1) [posaff]5.burst + [posaff]_cons = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | 2.409149 .0712306 33.82 0.000 2.269539 2.548758 ------------------------------------------------------------------------------

. * Slope12 at Burst 1 . lincom c.slope12*1 + c.slope12#i1.burst

( 1) [posaff]slope12 + [posaff]1b.burst#co.slope12 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2245959 .0483801 -4.64 0.000 -.3194192 -.1297726 ------------------------------------------------------------------------------

. * Slope12 at Burst 2 . lincom c.slope12*1 + c.slope12#i2.burst

( 1) [posaff]slope12 + [posaff]2.burst#c.slope12 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.1530694 .0507668 -3.02 0.003 -.2525705 -.0535684 ------------------------------------------------------------------------------

. * Slope12 at Burst 3 . lincom c.slope12*1 + c.slope12#i3.burst

( 1) [posaff]slope12 + [posaff]3.burst#c.slope12 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0403699 .0514251 -0.79 0.432 -.1411611 .0604214 ------------------------------------------------------------------------------

. * Slope12 at Burst 4 . lincom c.slope12*1 + c.slope12#i4.burst

( 1) [posaff]slope12 + [posaff]4.burst#c.slope12 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.0391804 .0533145 -0.73 0.462 -.1436749 .0653141 ------------------------------------------------------------------------------

. * Slope12 at Burst 5 . lincom c.slope12*1 + c.slope12#i5.burst

( 1) [posaff]slope12 + [posaff]5.burst#c.slope12 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .0157383 .0566441 0.28 0.781 -.0952821 .1267586 ------------------------------------------------------------------------------

. * Slope26 at Burst 1 . lincom c.slope26*1 + c.slope26#i1.burst

( 1) [posaff]slope26 + [posaff]1b.burst#co.slope26 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .011249 .0120779 0.93 0.352 -.0124233 .0349212 ------------------------------------------------------------------------------

. * Slope26 at Burst 2 . lincom c.slope26*1 + c.slope26#i2.burst

( 1) [posaff]slope26 + [posaff]2.burst#c.slope26 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .0121333 .0127266 0.95 0.340 -.0128104 .0370771 ------------------------------------------------------------------------------

. * Slope26 at Burst 3 . lincom c.slope26*1 + c.slope26#i3.burst

( 1) [posaff]slope26 + [posaff]3.burst#c.slope26 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .032825 .0128909 2.55 0.011 .0075592 .0580907 ------------------------------------------------------------------------------

. * Slope26 at Burst 4 . lincom c.slope26*1 + c.slope26#i4.burst

( 1) [posaff]slope26 + [posaff]4.burst#c.slope26 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .0148526 .0133286 1.11 0.265 -.0112711 .0409762 ------------------------------------------------------------------------------

. * Slope26 at Burst 5 . lincom c.slope26*1 + c.slope26#i5.burst

( 1) [posaff]slope26 + [posaff]5.burst#c.slope26 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | .0162098 .0142006 1.14 0.254 -.0116229 .0440425 ------------------------------------------------------------------------------

. estimates store FitPiecebyBurstMeansP,

. lrtest FitSatAllP FitPiecebyBurstMeansP,

Likelihood-ratio test LR chi2(15) = 15.95 (Assumption: FitPiecebyBu~P nested in FitSatAllP) Prob > chi2 = 0.3851

. . display as result "Eq 10b.11and12: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Eq 10b.11and12: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Three-Level Model for the Variance for Positive Affect" Three-Level Model for the Variance for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: , variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in personid equation; covariance structure set to identity Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1753.325 Iteration 1: log likelihood = -1753.325

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 72.27 Log likelihood = -1753.325 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0451263 .0100681 -4.48 0.000 -.0648593 -.0253932 slope12 | -.0119746 .0291711 -0.41 0.681 -.0691488 .0451997 | c.slope12#c.b1or2 | -.1926462 .040259 -4.79 0.000 -.2715524 -.1137399 | slope26 | .0173261 .0058144 2.98 0.003 .00593 .0287222 _cons | 2.573432 .0606517 42.43 0.000 2.454557 2.692307 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Identity | var(_cons) | .3261875 .0478305 .2447099 .4347936 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .0566794 .0062859 .0456062 .0704411 -----------------------------+------------------------------------------------ var(Residual) | .1546451 .0045757 .145932 .1638784 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(2) = 2540.43 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1753.325 8 3522.65 3544.107 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. lincom c.slope12*1 + c.slope12#c.b1or2*1 // Slope12 at Burst 1 or 2

( 1) [posaff]slope12 + [posaff]c.slope12#c.b1or2 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2046207 .0324168 -6.31 0.000 -.2681564 -.141085 ------------------------------------------------------------------------------

. estimates store FitPieceBurst1or2P,

. lrtest FitPiecebyBurstMeansP FitPieceBurst1or2P,

Likelihood-ratio test LR chi2(10) = 5.21 (Assumption: FitPieceBur~2P nested in FitPiecebyBu~P) Prob > chi2 = 0.8765

. lrtest FitSatAllP FitPieceBurst1or2P,

Likelihood-ratio test LR chi2(25) = 21.17 (Assumption: FitPieceBur~2P nested in FitSatAllP) Prob > chi2 = 0.6833

. . display as result "Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Random Linear Burst across Persons for Positive Affect" Add Random Linear Burst across Persons for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1, variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1741.6336 Iteration 1: log likelihood = -1741.5542 Iteration 2: log likelihood = -1741.5541

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 62.08 Log likelihood = -1741.5541 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0466484 .0127068 -3.67 0.000 -.0715532 -.0217435 slope12 | -.0114019 .0291498 -0.39 0.696 -.0685344 .0457305 | c.slope12#c.b1or2 | -.1940458 .0401782 -4.83 0.000 -.2727936 -.1152979 | slope26 | .0173501 .0058145 2.98 0.003 .0059538 .0287464 _cons | 2.574073 .0590674 43.58 0.000 2.458303 2.689843 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0075015 .002198 .0042242 .0133215 var(_cons) | .3171065 .0492531 .2338816 .4299462 cov(burst1,_cons) | -.0030382 .0079038 -.0185293 .0124529 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .038483 .0056786 .028818 .0513894 -----------------------------+------------------------------------------------ var(Residual) | .1546556 .0045762 .1459416 .1638899 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(4) = 2563.98 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1741.554 10 3503.108 3529.93 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0075015 _cons | -.0030382 .3171065

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | -.0622928 1

. estimates store FitRandBurstLin3P,

. lrtest FitRandBurstLin3P FitPieceBurst1or2P,

Likelihood-ratio test LR chi2(2) = 23.54 (Assumption: FitPieceBur~2P nested in FitRandBurs~3P) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Fixed and Random Quadratic Burst across Persons for Positive Affect" Add Fixed and Random Quadratic Burst across Persons for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26 /// > c.burst1#c.burst1, /// > || personid: burst1 burst1sq, variance mle covariance(unstructured) /// > || burst: , covariance(unstructured), Note: single-variable random-effects specification in burst equation; covariance structure set to identity

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1740.8307 Iteration 1: log likelihood = -1738.6478 Iteration 2: log likelihood = -1738.6248 Iteration 3: log likelihood = -1738.6248

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(5) = 61.49 Log likelihood = -1738.6248 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0592724 .034344 -1.73 0.084 -.1265854 .0080406 slope12 | -.0115499 .0291629 -0.40 0.692 -.0687082 .0456084 | c.slope12#c.b1or2 | -.1939415 .0402168 -4.82 0.000 -.272765 -.1151181 | slope26 | .0173518 .0058147 2.98 0.003 .0059553 .0287483 | c.burst1#c.burst1 | .0034946 .0078757 0.44 0.657 -.0119416 .0189307 | _cons | 2.578144 .0594371 43.38 0.000 2.46165 2.694639 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0377655 .017755 .0150284 .0949025 var(burst1sq) | .0013213 .0009302 .0003325 .0052513 var(_cons) | .3107503 .0499008 .2268424 .4256953 cov(burst1,burst1sq) | -.0063745 .0039267 -.0140706 .0013217 cov(burst1,_cons) | .001891 .0222695 -.0417564 .0455384 cov(burst1sq,_cons) | -.0023346 .0050295 -.0121922 .007523 -----------------------------+------------------------------------------------ burst: Identity | var(_cons) | .0320881 .0062047 .0219661 .0468744 -----------------------------+------------------------------------------------ var(Residual) | .1546624 .0045764 .145948 .1638972 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(7) = 2569.66 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1738.625 14 3505.25 3542.799 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 burst1sq _cons -------------+--------------------------------- burst1 | .0377655 burst1sq | -.0063745 .0013213 _cons | .001891 -.0023346 .3107503

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 burst1sq _cons -------------+--------------------------------- burst1 | 1 burst1sq | -.9023887 1 _cons | .0174558 -.1152118 1

. estimates store FitRandBurstQuad3P,

. lrtest FitRandBurstQuad3P FitRandBurstLin3P,

Likelihood-ratio test LR chi2(4) = 5.86 (Assumption: FitRandBurs~3P nested in FitRandBurs~3P) Prob > chi2 = 0.2100

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Random Linear Slope12 across Bursts for Positive Affect" Add Random Linear Slope12 across Bursts for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1, variance mle covariance(unstructured) /// > || burst: slope12, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1732.4468 Iteration 1: log likelihood = -1731.998 Iteration 2: log likelihood = -1731.9973 Iteration 3: log likelihood = -1731.9973

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 55.86 Log likelihood = -1731.9973 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0464781 .0127425 -3.65 0.000 -.0714529 -.0215033 slope12 | -.0105262 .0321616 -0.33 0.743 -.0735618 .0525094 | c.slope12#c.b1or2 | -.1957484 .045241 -4.33 0.000 -.2844192 -.1070777 | slope26 | .0172927 .0056116 3.08 0.002 .006294 .0282913 _cons | 2.573746 .0590767 43.57 0.000 2.457957 2.689534 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0074955 .0021969 .0042201 .0133131 var(_cons) | .3176082 .0495009 .2340062 .4310781 cov(burst1,_cons) | -.0030325 .0079121 -.0185401 .012475 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .063641 .0166456 .0381154 .1062608 var(_cons) | .0418009 .0063762 .0309988 .0563671 cov(slope12,_cons) | .0100355 .0082626 -.0061588 .0262298 -----------------------------+------------------------------------------------ var(Residual) | .1440331 .0047658 .1349887 .1536835 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(6) = 2583.09 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1731.997 12 3487.995 3520.18 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | .0074955 _cons | -.0030325 .3176082

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 _cons -------------+---------------------- burst1 | 1 _cons | -.062153 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | .063641 _cons | .0100355 .0418009

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | 1 _cons | .1945714 1

. estimates store FitRandSlope12at2P,

. lrtest FitRandSlope12at2P FitRandBurstLin3P,

Likelihood-ratio test LR chi2(2) = 19.11 (Assumption: FitRandBurs~3P nested in FitRandSlop~2P) Prob > chi2 = 0.0001

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Random Linear Slope12 across Persons for Positive Affect" Add Random Linear Slope12 across Persons for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1 slope12, variance mle covariance(unstructured) /// > || burst: slope12, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1720.1036 Iteration 1: log likelihood = -1718.4318 Iteration 2: log likelihood = -1718.4185 Iteration 3: log likelihood = -1718.4185

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 55.40 Log likelihood = -1718.4185 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0458576 .0126849 -3.62 0.000 -.0707196 -.0209955 slope12 | -.0175468 .0355707 -0.49 0.622 -.0872641 .0521705 | c.slope12#c.b1or2 | -.1952573 .0421846 -4.63 0.000 -.2779375 -.112577 | slope26 | .0172575 .0056115 3.08 0.002 .0062592 .0282558 _cons | 2.572517 .0604893 42.53 0.000 2.45396 2.691074 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0075149 .0022016 .004232 .0133444 var(slope12) | .0355946 .0118085 .018578 .0681978 var(_cons) | .3370042 .0521226 .2488769 .4563374 cov(burst1,slope12) | .0016119 .0034793 -.0052075 .0084312 cov(burst1,_cons) | -.0032454 .0081031 -.0191273 .0126364 cov(slope12,_cons) | .059022 .0187265 .0223188 .0957251 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .0281096 .016177 .0090989 .0868395 var(_cons) | .0395538 .0060423 .0293195 .0533604 cov(slope12,_cons) | .0002913 .0071279 -.0136791 .0142618 -----------------------------+------------------------------------------------ var(Residual) | .1440272 .0047656 .1349833 .1536771 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(9) = 2610.25 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1718.419 15 3466.837 3507.069 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | .0075149 slope12 | .0016119 .0355946 _cons | -.0032454 .059022 .3370042

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | 1 slope12 | .0985541 1 _cons | -.0644902 .5388943 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | .0281096 _cons | .0002913 .0395538

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 _cons -------------+---------------------- slope12 | 1 _cons | .0087376 1

. estimates store FitRandSlope12at23P,

. lrtest FitRandSlope12at23P FitRandSlope12at2P, force

Likelihood-ratio test LR chi2(3) = 27.16 (Assumption: FitRandSlop~2P nested in FitRandSlo~23P) Prob > chi2 = 0.0000

. . display as result "Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Ch 10b: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Random Linear Slope26 across Bursts for Positive Affect" Add Random Linear Slope26 across Bursts for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1 slope12, variance mle covariance(unstructured) /// > || burst: slope12 slope26, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1716.1042 Iteration 1: log likelihood = -1712.9724 Iteration 2: log likelihood = -1712.9215 Iteration 3: log likelihood = -1712.9214

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 54.87 Log likelihood = -1712.9214 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0454578 .0125592 -3.62 0.000 -.0700735 -.0208422 slope12 | -.0186313 .0350211 -0.53 0.595 -.0872714 .0500089 | c.slope12#c.b1or2 | -.192637 .0421474 -4.57 0.000 -.2752444 -.1100297 | slope26 | .0171986 .0059992 2.87 0.004 .0054404 .0289569 _cons | 2.571882 .0610517 42.13 0.000 2.452222 2.691541 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0072541 .0021556 .0040518 .0129874 var(slope12) | .0333611 .0116208 .0168553 .0660303 var(_cons) | .3400255 .0525445 .2511738 .4603081 cov(burst1,slope12) | .0012682 .0033967 -.0053892 .0079257 cov(burst1,_cons) | -.0031354 .0080271 -.0188683 .0125975 cov(slope12,_cons) | .0576154 .0185722 .0212146 .0940161 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .0317297 .0199663 .0092435 .1089168 var(slope26) | .0027606 .0012144 .0011656 .006538 var(_cons) | .0629268 .0121192 .043142 .0917848 cov(slope12,slope26) | -.0013289 .003605 -.0083946 .0057368 cov(slope12,_cons) | .0097419 .0116005 -.0129947 .0324785 cov(slope26,_cons) | -.0082264 .0032799 -.014655 -.0017979 -----------------------------+------------------------------------------------ var(Residual) | .1371476 .0052431 .1272469 .1478186 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(12) = 2621.24 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1712.921 18 3461.843 3510.121 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | .0072541 slope12 | .0012682 .0333611 _cons | -.0031354 .0576154 .3400255

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope12 _cons -------------+--------------------------------- burst1 | 1 slope12 | .0815233 1 _cons | -.0631312 .540957 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | .0317297 slope26 | -.0013289 .0027606 _cons | .0097419 -.0082264 .0629268

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | 1 slope26 | -.1419886 1 _cons | .2180181 -.6241541 1

. estimates store FitRandSlope26at2P,

. lrtest FitRandSlope26at2P FitRandSlope12at23P,

Likelihood-ratio test LR chi2(3) = 10.99 (Assumption: FitRandSlo~23P nested in FitRandSlop~2P) Prob > chi2 = 0.0118

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . display as result "Eq 10b.13: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2" Eq 10b.13: Piecewise Session Slopes, Linear Burst, Slope12 by Burst1or2

. display as result "Add Random Linear Slope26 across Persons for Positive Affect" Add Random Linear Slope26 across Persons for Positive Affect

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1 slope12 slope26, variance mle covariance(unstructured) /// > || burst: slope12 slope26, covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1710.8396 Iteration 1: log likelihood = -1706.4108 Iteration 2: log likelihood = -1706.2931 Iteration 3: log likelihood = -1706.291 Iteration 4: log likelihood = -1706.291

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747

----------------------------------------------------------- | No. of Observations per Group Group Variable | Groups Minimum Average Maximum ----------------+------------------------------------------ personid | 108 4 25.4 30 burst | 462 1 5.9 6 -----------------------------------------------------------

Wald chi2(4) = 57.67 Log likelihood = -1706.291 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0451101 .01253 -3.60 0.000 -.0696685 -.0205518 slope12 | -.0158038 .0334038 -0.47 0.636 -.081274 .0496664 | c.slope12#c.b1or2 | -.1940035 .0421584 -4.60 0.000 -.2766324 -.1113745 | slope26 | .0160071 .0067886 2.36 0.018 .0027016 .0293125 _cons | 2.573924 .0584683 44.02 0.000 2.459328 2.68852 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0071941 .0021487 .0040063 .0129184 var(slope12) | .0214065 .0120304 .0071149 .064405 var(slope26) | .0013223 .0007078 .0004631 .0037752 var(_cons) | .3069705 .0504973 .2223679 .4237612 cov(burst1,slope12) | -.0000682 .0034065 -.0067447 .0066083 cov(burst1,slope26) | .000639 .0008402 -.0010076 .0022857 cov(burst1,_cons) | -.0048056 .007899 -.0202874 .0106762 cov(slope12,slope26) | .0020752 .0021443 -.0021274 .0062779 cov(slope12,_cons) | .0369675 .018135 .0014235 .0725116 cov(slope26,_cons) | .0062512 .0042516 -.0020817 .0145842 -----------------------------+------------------------------------------------ burst: Unstructured | var(slope12) | .0353523 .0210495 .0110051 .1135641 var(slope26) | .0014414 .0012585 .0002604 .0079791 var(_cons) | .0605116 .0122123 .0407428 .0898725 cov(slope12,slope26) | -.0010621 .0037995 -.008509 .0063848 cov(slope12,_cons) | .0109375 .0122531 -.0130781 .0349531 cov(slope26,_cons) | -.006213 .0033236 -.012727 .0003011 -----------------------------+------------------------------------------------ var(Residual) | .1371382 .0052425 .1272387 .147808 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(16) = 2634.50 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1706.291 22 3456.582 3515.589 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope12 slope26 _cons -------------+-------------------------------------------- burst1 | .0071941 slope12 | -.0000682 .0214065 slope26 | .000639 .0020752 .0013223 _cons | -.0048056 .0369675 .0062512 .3069705

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope12 slope26 _cons -------------+-------------------------------------------- burst1 | 1 slope12 | -.0054953 1 slope26 | .2071902 .3900563 1 _cons | -.1022608 .4560364 .3102773 1

. estat recovariance, relevel(burst),

Random-effects covariance matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | .0353523 slope26 | -.0010621 .0014414 _cons | .0109375 -.006213 .0605116

. estat recovariance, relevel(burst) correlation,

Random-effects correlation matrix for level burst

| slope12 slope26 _cons -------------+--------------------------------- slope12 | 1 slope26 | -.1487911 1 _cons | .2364779 -.6652489 1

. lincom c.slope12*1 + c.slope12#c.b1or2*1 // Slope12 at Burst 1 or 2

( 1) [posaff]slope12 + [posaff]c.slope12#c.b1or2 = 0

------------------------------------------------------------------------------ posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- (1) | -.2098073 .0362321 -5.79 0.000 -.2808209 -.1387937 ------------------------------------------------------------------------------

. estimates store FitRandSlope26at23P,

. lrtest FitRandSlope26at23P FitRandSlope26at2P,

Likelihood-ratio test LR chi2(4) = 13.26 (Assumption: FitRandSlop~2P nested in FitRandSlo~23P) Prob > chi2 = 0.0101

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. predict PredUncP, xb,

. margins, at (c.slope12=-1 c.slope26=0 c.b1or2=1 c.burst1=(0(1)1)) vsquish,

Adjusted predictions Number of obs = 2747

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 0 slope12 = -1 b1or2 = 1 slope26 = 0 2._at : burst1 = 1 slope12 = -1 b1or2 = 1 slope26 = 0

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 2.783731 .0588962 47.27 0.000 2.668297 2.899166 2 | 2.738621 .057845 47.34 0.000 2.625247 2.851995 ------------------------------------------------------------------------------

. margins, at (c.slope12=-1 c.slope26=0 c.b1or2=0 c.burst1=(2(1)4)) vsquish,

Adjusted predictions Number of obs = 2747

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 2 slope12 = -1 b1or2 = 0 slope26 = 0 2._at : burst1 = 3 slope12 = -1 b1or2 = 0 slope26 = 0 3._at : burst1 = 4 slope12 = -1 b1or2 = 0 slope26 = 0

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 2.499508 .0574972 43.47 0.000 2.386815 2.6122 2 | 2.454397 .0603448 40.67 0.000 2.336124 2.572671 3 | 2.409287 .0655062 36.78 0.000 2.280897 2.537677 ------------------------------------------------------------------------------

. margins, at (c.slope12=0 c.slope26=(0(1)4) c.b1or2=1 c.burst1=(0(1)1)) vsquish,

Adjusted predictions Number of obs = 2747

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 0 slope12 = 0 b1or2 = 1 slope26 = 0 2._at : burst1 = 0 slope12 = 0 b1or2 = 1 slope26 = 1 3._at : burst1 = 0 slope12 = 0 b1or2 = 1 slope26 = 2 4._at : burst1 = 0 slope12 = 0 b1or2 = 1 slope26 = 3 5._at : burst1 = 0 slope12 = 0 b1or2 = 1 slope26 = 4 6._at : burst1 = 1 slope12 = 0 b1or2 = 1 slope26 = 0 7._at : burst1 = 1 slope12 = 0 b1or2 = 1 slope26 = 1 8._at : burst1 = 1 slope12 = 0 b1or2 = 1 slope26 = 2 9._at : burst1 = 1 slope12 = 0 b1or2 = 1 slope26 = 3 10._at : burst1 = 1 slope12 = 0 b1or2 = 1 slope26 = 4

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 2.573924 .0584683 44.02 0.000 2.459328 2.68852 2 | 2.589931 .0585831 44.21 0.000 2.47511 2.704752 3 | 2.605938 .0594776 43.81 0.000 2.489364 2.722512 4 | 2.621945 .0611177 42.90 0.000 2.502157 2.741734 5 | 2.637952 .0634454 41.58 0.000 2.513602 2.762303 6 | 2.528814 .056597 44.68 0.000 2.417886 2.639742 7 | 2.544821 .056833 44.78 0.000 2.43343 2.656212 8 | 2.560828 .05787 44.25 0.000 2.447405 2.674251 9 | 2.576835 .0596662 43.19 0.000 2.459892 2.693779 10 | 2.592842 .0621558 41.72 0.000 2.471019 2.714665 ------------------------------------------------------------------------------

. margins, at (c.slope12=0 c.slope26=(0(1)4) c.b1or2=0 c.burst1=(2(1)4)) vsquish,

Adjusted predictions Number of obs = 2747

Expression : Linear prediction, fixed portion, predict() 1._at : burst1 = 2 slope12 = 0 b1or2 = 0 slope26 = 0 2._at : burst1 = 2 slope12 = 0 b1or2 = 0 slope26 = 1 3._at : burst1 = 2 slope12 = 0 b1or2 = 0 slope26 = 2 4._at : burst1 = 2 slope12 = 0 b1or2 = 0 slope26 = 3 5._at : burst1 = 2 slope12 = 0 b1or2 = 0 slope26 = 4 6._at : burst1 = 3 slope12 = 0 b1or2 = 0 slope26 = 0 7._at : burst1 = 3 slope12 = 0 b1or2 = 0 slope26 = 1 8._at : burst1 = 3 slope12 = 0 b1or2 = 0 slope26 = 2 9._at : burst1 = 3 slope12 = 0 b1or2 = 0 slope26 = 3 10._at : burst1 = 3 slope12 = 0 b1or2 = 0 slope26 = 4 11._at : burst1 = 4 slope12 = 0 b1or2 = 0 slope26 = 0 12._at : burst1 = 4 slope12 = 0 b1or2 = 0 slope26 = 1 13._at : burst1 = 4 slope12 = 0 b1or2 = 0 slope26 = 2 14._at : burst1 = 4 slope12 = 0 b1or2 = 0 slope26 = 3 15._at : burst1 = 4 slope12 = 0 b1or2 = 0 slope26 = 4

------------------------------------------------------------------------------ | Delta-method | Margin Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- _at | 1 | 2.483704 .0574621 43.22 0.000 2.37108 2.596327 2 | 2.499711 .0578101 43.24 0.000 2.386405 2.613017 3 | 2.515718 .0589431 42.68 0.000 2.400192 2.631244 4 | 2.531725 .0608173 41.63 0.000 2.412525 2.650925 5 | 2.547732 .0633669 40.21 0.000 2.423535 2.671929 6 | 2.438594 .0609473 40.01 0.000 2.319139 2.558048 7 | 2.454601 .0613842 39.99 0.000 2.33429 2.574912 8 | 2.470608 .0625591 39.49 0.000 2.347994 2.593221 9 | 2.486615 .0644316 38.59 0.000 2.360331 2.612898 10 | 2.502622 .0669432 37.38 0.000 2.371416 2.633828 11 | 2.393483 .0666427 35.92 0.000 2.262866 2.524101 12 | 2.409491 .0671419 35.89 0.000 2.277895 2.541086 13 | 2.425498 .0683154 35.50 0.000 2.291602 2.559393 14 | 2.441505 .0701293 34.81 0.000 2.304054 2.578956 15 | 2.457512 .0725356 33.88 0.000 2.315345 2.599679 ------------------------------------------------------------------------------

. corr posaff PredUncP (obs=2747)

| posaff PredUncP -------------+------------------ posaff | 1.0000 PredUncP | 0.1090 1.0000



. . display as result "Ch 10b: Final Unconditional Model for Positive Affect" Ch 10b: Final Unconditional Model for Positive Affect

. display as result "Removing Level-2 Random Effects Variances and Covariances" Removing Level-2 Random Effects Variances and Covariances

. mixed posaff c.burst1 c.slope12 c.slope12#c.b1or2 c.slope26, /// > || personid: burst1 slope12 slope26, variance mle covariance(unstructured),

Performing EM optimization:

Performing gradient-based optimization:

Iteration 0: log likelihood = -1783.0551 Iteration 1: log likelihood = -1782.2876 Iteration 2: log likelihood = -1782.2401 Iteration 3: log likelihood = -1782.2365 Iteration 4: log likelihood = -1782.2364

Computing standard errors:

Mixed-effects ML regression Number of obs = 2747 Group variable: personid Number of groups = 108

Obs per group: min = 4 avg = 25.4 max = 30



Wald chi2(4) = 62.96 Log likelihood = -1782.2364 Prob > chi2 = 0.0000

----------------------------------------------------------------------------------- posaff | Coef. Std. Err. z P>|z| [95% Conf. Interval] ------------------+---------------------------------------------------------------- burst1 | -.0469074 .0125342 -3.74 0.000 -.071474 -.0223408 slope12 | -.0117781 .0332119 -0.35 0.723 -.0768722 .0533159 | c.slope12#c.b1or2 | -.2037908 .0419766 -4.85 0.000 -.2860634 -.1215181 | slope26 | .016143 .0068026 2.37 0.018 .0028101 .029476 _cons | 2.572251 .0584622 44.00 0.000 2.457668 2.686835 -----------------------------------------------------------------------------------

------------------------------------------------------------------------------ Random-effects Parameters | Estimate Std. Err. [95% Conf. Interval] -----------------------------+------------------------------------------------ personid: Unstructured | var(burst1) | .0112076 .0021025 .0077595 .0161879 var(slope12) | .0163753 .0110789 .0043481 .0616708 var(slope26) | .0008998 .0006663 .0002108 .0038414 var(_cons) | .3305789 .0502067 .2454703 .4451962 cov(burst1,slope12) | -.0000394 .0033902 -.006684 .0066052 cov(burst1,slope26) | .0006353 .0008382 -.0010075 .0022781 cov(burst1,_cons) | -.0113276 .0078818 -.0267756 .0041205 cov(slope12,slope26) | .0034552 .0019577 -.0003819 .0072923 cov(slope12,_cons) | .0357959 .0179491 .0006163 .0709755 cov(slope26,_cons) | .0062738 .0042158 -.001989 .0145366 -----------------------------+------------------------------------------------ var(Residual) | .1714907 .0050148 .1619382 .1816067 ------------------------------------------------------------------------------ LR test vs. linear regression: chi2(10) = 2482.61 Prob > chi2 = 0.0000

Note: LR test is conservative and provided only for reference.

. estat ic, n(108),

Akaike's information criterion and Bayesian information criterion

----------------------------------------------------------------------------- Model | Obs ll(null) ll(model) df AIC BIC -------------+--------------------------------------------------------------- . | 108 . -1782.236 16 3596.473 3639.387 ----------------------------------------------------------------------------- Note: N=108 used in calculating BIC

. estat recovariance, relevel(personid),

Random-effects covariance matrix for level personid

| burst1 slope12 slope26 _cons -------------+-------------------------------------------- burst1 | .0112076 slope12 | -.0000394 .0163753 slope26 | .0006353 .0034552 .0008998 _cons | -.0113276 .0357959 .0062738 .3305789

. estat recovariance, relevel(personid) correlation,

Random-effects correlation matrix for level personid

| burst1 slope12 slope26 _cons -------------+-------------------------------------------- burst1 | 1 slope12 | -.0029084 1 slope26 | .2000619 .9001093 1 _cons | -.1860983 .4865194 .363755 1

. estimates store FitNo2P,

. lrtest FitRandSlope26at23P FitNo2P,

Likelihood-ratio test LR chi2(6) = 151.89 (Assumption: FitNo2P nested in FitRandSlo~23P) Prob > chi2 = 0.0000

Note: The reported degrees of freedom assumes the null hypothesis is not on the boundary of the parameter space. If this is not true, then the reported test is conservative.

. . ****** END CHAPTER 10b MODELS ****** . . * Close log . log close STATA_Chapter10b name: STATA_Chapter10b log: C:\Dropbox\PilesOfVariance\Chapter10b\STATA\STATA_Chapter10b_Output.smcl log type: smcl closed on: 30 Jan 2015, 12:23:46 ------------------------------------------------------------------------------------------------------------------------------------------------------