![]() |
|
Readme fileSERIES B
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
1.
|
bartlett.f: Driver program |
|
2.
|
linsubs.f: Code by M. Lindstrom and D. Bates for fitting mixed linear models (JASA, 1988, 83:1014-1022) |
|
3.
|
scrtch.m: A file of code referenced by linsubs.f in a few places |
|
4.
|
linpack.f: LINPACK subroutines used in the Lindstrom-Bates code |
|
5.
|
eispack.f: EISPACK subroutines used in the Lindstrom-Bates code |
|
6.
|
bdzsubs.f: Subroutines written by D. Zucker for computing Bartlett correction and adjusted likelihood |
|
7.
|
matcom.f: Routines for computing the determinant and the inverse of a symmetric matrix, based on LINPACK subroutines |
|
8.
|
fmin.f: Netlib code for Brent's line search algorithm |
| We also include the following files: | |
|
9.
|
cntlb.crd: "Control card" file for the Gaucher example in the paper |
|
10.
|
gaubar.dat: Data file for the Gaucher example |
The observation pattern files for the simulations reported in Section
4 of the paper are constructed from the file gaubar.dat as follows:
* For n=15: ID's 1, 2, 4, 5, 9, 13, 15, 16, 18, 19, 23, 24, 25, 26,
28
* For n=20: ID's 1, 2, 3, 4, 5, 6, 9, 10, 13, 14, 15, 16, 17, 18, 19,
23, 24, 25, 26, 28
* For n=30: ID's 11 and 21 are duplicated We thank Mary Lindstrom for
giving us permission to include her code in our posting.
We point out that Lindstrom's code is being made available on an "as-is" basis and is not supported or guaranteed in any way. For those interested, an S-plus version of the Lindstom-Bates code is available at the following website: http://cm.bell-labs.com/cm/ms/departments/sia/project/nlme/index.html
The software posted here can handle a mixed linear model of the form
y_i = X_i \beta + Z_i b_i + \epsilon_i,
where the covariance matrix D of the random effects vector b_i is unstructured and the covariance matrix R_i of the error vector \epsilon_i is a multiple of the identity matrix.
To run the code it is necessary to prepare a "control card" file named cntlb.crd and a data file.
The file cntlb.crd must contain 8 lines as follows:
|
1.
|
Name of data file |
|
2.
|
The digit 0 or 1, according to whether conventional or adjusted likelihood is desired |
|
3.
|
The number of independent units (clusters) of data (n) |
|
4.
|
The total number of observations (T) |
|
5.
|
The number of fixed effect parameters (length of \beta) (k) |
|
6.
|
The number of random effect parameters (length of b_i) (m) |
|
7.
|
The index of the fixed effect parameter which one desires to test |
|
8.
|
The digit 0 or 1, according to whether the Newton-Raphson or EM method of fitting is desired |
| The data file should be prepared in the following manner: | |
|
There should be a separate record for each observation.
The record should contain, in succession, the following data:
|
|
|
1.
|
The id number of the unit from which the observation derives |
|
2.
|
The elements of the X matrix for the observation in question |
|
3.
|
The elements of the Z matrix for the observation in question. |
|
4.
|
The response value y for the observation in question. |
| The id numbers must be the integers 1 to n in order. | |
|
We include in this web posting the cntlb.crd file
and the data file (gaubar.dat) for the Gaucher's disease example
reported in our paper.
|
|
| Some remarks and cautions: | |
|
1.
|
Conventional maximum likelihood fitting for mixed linear models is available in a number of canned routines such as SAS PROC MIXED, BMDP5V, ML3, or the Lindstrom-Bates S-plus code. A modified driver program may be obtained from David Zucker that takes as inputs the estimates of the fixed and random effects parameters and the loglikelihood value under the full model and the null hypothesis (which may be obtained from the canned routines) and proceeds directly to the computation of the Bartlett corrected statistic. The code as it stands is set up to handle only models with an unstructured D matrix and R_i matrices that are a multiple of the identity, but the code may be fairly easily modified to handle covariance matrices with linear structure by suitably modifying the subroutine qcomp in the file bdzsubs.f. |
|
2.
|
We initially had a number of problems getting the Lindstrom-Bates code to work when moving from one computer system to another. We believe we now ironed out these problems, and we expect and hope that others will be able to run the code without trouble. If nonetheless you run into problems, you may have to consult a Fortran expert at your institution. If you unable to get the code running, there are two options for getting around the problem, depending on your needs. |
| a. | If you want to use the conventional likelihood with the Bartlett correction in the analysis of a particular data set, you may use the modified driver program described in Remark 1. |
| b. | If you want to do simulations or you want to use the adjusted likelihood method, you will have to replace the Lindstrom-Bates code by some other code and make appropriate modifications to the driver program and the subroutine opt in the file bdzsubs.f (which serves as the interface between the driver program and the model fitting code). |
| 3. | In the adjusted likelihood computations reported in our paper, we used code for Brent's line search algorithm in the Numerical Recipes (Press et al.) library. Because this code is proprietary, for this web posting the code has been replaced by similar nonproprietary code obtained from netlib (http://www.netlib.org). In our original program, we preceded the call to the Brent routine by the Numerical Recipes minimum point bracketing routine mnbrak, but the code in the current posting omits this step because we have been unable to find a nonproprietary version. Those interested in the bracketing routine may check the Numerical Recipes website (http://www.nr.org) and may consult David Zucker for the changes that have to be made to get the code to mesh with our program. |
Contact person for questions about this material:
David Zucker
Department of Statistics
Hebrew University of Jerusalem
Mount Scopus
91905 Jerusalem
Israel
E-mail: mszucker@mscc.huji.ac.il
SERIES A
Statistics in
Society
SERIES B
Statistical
Methodology
SERIES C
Applied
Statistics
SERIES D
The
Statistician