UCLA Academic Technology Services HomeServicesClassesContactJobs
Search

MLwiN Textbook Examples
Applied Longitudinal Data Analysis: Modeling Change and Event Occurrence
by Judith D. Singer and John B. Willett
Chapter 5:  Treating TIME more flexibly


Table 5.2 on page 145 using data set reading_pp.ws.

The model shown below uses the centered agegrp variable, called cagegrp, as the predictor.  This variable is random at level 2, and the intercept (cons) is random at levels 1 and 2.

The results of running this model are shown below.

The model shown below uses the centered age variable called cage as the predictor variable.  This variable is random at level 2, and the intercept (cons) is random at both levels 1 and 2.

The results of running this model are shown below.


Table 5.4 on page 149 using data set wages_pp.ws.

Model A:

The model shown below has an intercept (cons) that is random at both levels 1 and 2 and a single predictor, exper, which is random at level 2.  This is the unconditional growth model.

The results of running this model are shown below.

Model B:

The model shown below is the same as the one used in Model A, except another predictor, hgc_9, and two interaction terms, hgc_9*black and hgc_9*exper, have been added.  All three of these terms are fixed.

The results of running the above model are shown below.

Model C:

Model C is a reduced model compared to Model B.  The terms black and black*hgc_9 have been removed.

The results of running the above model are shown below.


   Figure 5.2 on page 150, skipped for now.


Table 5.5, page 154

Model A:  Default method

The results of running the above model are shown below.

Model B:  Removing boundary constraints

To remove the boundary constraints in MLwinN, click on the "Estimation Control" button and click on "At level 1" to change it from "NO" to "YES".  Click on "At level 2" to change it from "NO" to "YES".  We also checked the box to suppress numeric warnings so that MLwiN would continue until either convergence or the iteration limit was reached.  The estimation control dialogue box is shown below with the settings necessary to run Model B.

The results shown below are the results of running Model A with the changes to the estimation control shown above.  Our results differ somewhat from those shown in the text, and we do not know why.  There were 142 iterations before the model converged.

Model C:

The only difference between Model C and Model A is that the variable exper is fixed in Model C, while it is random at level 2 in Model A.

The results of running the above model are shown below.


Table 5.7, page 163 using data set unemployment_pp.ws.

Model A:

This is an unconditional growth model.  The constant (cons) is random at levels 1 and 2, and time is random at level 2.

The results of running the above model are shown below.

Model B:

Model B is the same as Model A, except the variable unemp as been added.  This variable is fixed.

The results of running the above model are shown below.

Model C:

Model C is the same as Model B, except that the interaction between unemp and months, called unemp*months, as been added.  This variable is fixed.

The results of running the above model are shown below.

Model D:

Model D is the same as Model C, except that the variable unemp is now random at level 2, and the variable months as been removed.  (CHECK ON THIS)

The results of running the above model are shown below.


Figure 5.4, page 167 based on the previous example.

For all graphs in this figure, the top line represents unemp = 1 and the bottom line represents unemp = 2.

Left panel:

To produce this graph, we ran Model B.  Next, we clicked on "Equations" and then "Predictions" and saved the predicted value to a new variable (as we did in chapter 4).  Then we clicked on "Graphs" and then "Customized Graph(s)" to create each of the graphs in this figure.

Middle panel:

Right panel:


Table 5.8 on page 175 using data set wages_pp.ws.

Model A:  Centered at 7

In this model, time is centered at 7.  The intercept (cons) is random at levels 1 and 2, and exper is random at level 2.

The results of running the above model are shown below.

Model B:  Within-context centering

The results of running the above model are shown below.

Model C:  Time-1 centered

The results of running the above model are shown below.


Table 5.10 on  page 184 using data set medication_pp.ws.

Temporal predictor in level 1 model:  Time

The results of running this model are shown below.

Temporal predictor in level 1 model:  Time-3.33

The results of running this model are shown below.

Temporal predictor in level 1 model:  Time-6.67

The results of running this model are shown below.


Figure 5.5 on page 185 based on the previous model.

This figure is based on the first equation presented in Table 5.10 in which time is used as a predictor.  We obtain the predicted values of pos in the same way that we did above and in chapter 4. 


How to cite this page

Report an error on this page

UCLA Researchers are invited to our Statistical Consulting Services
We recommend others to our list of Other Resources for Statistical Computing Help
These pages are Copyrighted (c) by UCLA Academic Technology Services


The content of this web site should not be construed as an endorsement of any particular web site, book, or software product by the University of California