Identifying Better Links and Families for GLM and GEE Models

The glmdiagl and geediag buttons below provide Stata programs, data, and documentation for identifying better links and families for generalized linear models (GLM) used to predict continuous outcomes. The programs report tests of fit for different links and families. The program that directly runs the tests themselves (glmdiag) is used after a GLM has been estimated. The programs that evaluate better links and families over a range of links (glmdiagl and glmdiagl2) run a series of glms after each of which they run glmdiag. Examples are provided using the eeict2011.dta dataset that is used for several of the other sets of programs available on the website.

It is an open question whether when bootstrapping a glm model, the link and family from the parent analysis should be used for each of the bootstrap replicates or whether replicate-specific links and families should be used. In addition, there are bootstrap replicates where the link and family from the parent analysis will not run. The errorcapture.do file attempts to address these issues in the bootstrap context by offering code that detects whether a glm has run and if not runs glmdiagl to identify a better link/family combination that will run.

The GEEDiag button provides a stata program (geediag) that runs the same tests for a prespecified link and family for a generalized estimating equation (GEE). As with glmdiag, geediag is used after a specific GEE has been estimated. At the moment, there is no geediagl program for distribution that evaluates better links and families over a range of links.

For background about links and families, see the program documentation, chapter 5 in Glick, et al., Economic Evaluation in Clinical Trials or the lectures on cost analysis in the EPI 550 Medical Decision Making and Clinical Economics and Lectures by Invitation tabs. For the latter, particularly see “Identifying an Appropriate Link and Family for Generalized Linear Models,†ISPOR 20th Annual International Meeting, May 19, 2015, Philadelphia, Pennsylvania.

THE GLMDIAGLNEW ZIP FILE

THE GEEDIAG ZIP FILE

Back to Stata Files page