Supplement 1. Matlab computer code for PGLMM estimation and data simulation.
File List
PGLMM_funct.m
PGLMM_REML_funct.m
PGLMM_REML_tozero_funct.m
PGLMM_nosparse_funct.m
PGLMM_REML_nosparse_funct.m
PGLMM_REML_tozero_nosparse_funct.m
fminsearchNoMsg.m
PGLMM_model_simulations.m
All files at once
Description
The matlab function PGLMM_funct.m performs our implementation of PGLMM estimation. This function calls PGLMM_REML_funct.m and PGLMM_REML_tozero_funct.m. All three of these programs have versions in which sparse matrices are not used (PGLMM_nosparse_funct.m, PGLMM_REML_nosparse_funct.m, and PGLMM_REML_tozero_nosparse_funct.m); these versions run faster when matrices have few zeros, as in the case of model II in the article. The program fminsearchNoMsg.m is a version of fminsearch.m that does not print warning messages. The program PGLMM_model_simulations.m simulates data sets used for models I-V in the text and estimates parameters from the corresponding PGLMMs with a call to PGLMM_funct.m.