Richard Williams, Notre Dame Sociology

gologit2: Generalized ordered logit/ partial proportional odds models for ordinal dependent variables

Richard Williams, University of Notre Dame

Note:  oglm is gologit2 's younger sibling.  Click here for its support page.  Much of the material on this page (e.g. the Troubleshooting FAQ) may also be useful for oglm.

Readings.  This presentation (powerpoint or pdf ; related handout) covers highlights of gologit2.  This paper that appeared in The Stata Journal provides a more in-depth discussion.  If you use gologit2 in published work, you can cite it. (For updates since the paper was published, also see this.) You can also see this 2016 paper from The Journal of Mathematical Sociology, "Understanding and interpreting generalized ordered logit models." (Complete article is here.)

This July 2006 followup presentation (powerpoint or pdfrelated handout) discusses "Interpreting and using heterogeneous choice & generalized ordered logit models." It raises several issues that users of gologit may not be aware of and argues that heterogeneous choice models (which can be estimated with oglm) can sometimes be an attractive alternative to gologit models.

I highly recommend this working paper on Income and Happiness by Stephan Boes and Rainer Winkelmann.  The authors did not use gologit2 when they wrote the paper but subsequently confirmed that gologit2 produces identical results. This is a good paper for understanding one of the rationales for a gologit model and for showing how the results can be interpreted.

If you are having problems with  gologit2, then check out the Troubleshooting FAQ. The FAQ tells you how to deal with many of the problems people have written me about.  In addition, the FAQ offers advice on when you may want to choose a different technique altogether.

Overviewgologit2 is a user-written program that estimates generalized ordered logit models for ordinal dependent variables.  The actual values taken on by the dependent variable are irrelevant except that larger values are assumed to correspond to "higher" outcomes. gologit2 is inspired by Vincent Fu's gologit program and is backward compatible with it but offers several additional powerful options. 

A major strength of gologit2 is that it can also estimate three special cases of the generalized model: the proportional odds/parallel lines model, the partial proportional odds model, and the logistic regression model. Hence, gologit2 can estimate models that are less restrictive than the proportional odds /parallel lines models estimated by ologit (whose assumptions are often violated) but more parsimonious and interpretable than those estimated by a non-ordinal method, such as multinomial logistic regression (i.e. mlogit).

Other key strengths of gologit2 include options for linear constraints, alternative model parameterizations, automated model fitting, survey data (svy) estimation, alternative link functions (logit, probit, complementary log-log and log-log), and the computation of estimated probabilities via the predict command. gologit2 works under both Stata 8.2 and Stata 9 or higher. Syntax is the same for both versions; but if you are using Stata 9 or higher, gologit2 supports several prefix commands, including by, nestreg, xi and sw.

To install gologit2:  From within Stata, type

findit gologit2

Data Sets and Do files.  Here are the data sets used in my 2006 Stata Journal paper, in case you want to replicate my examples or try additional analyses yourself: lall.dta, nhanes2f.dta, and ordwarm2.dta.

For the 2016 Journal Of Mathematic Sociology article, here are the do files for Table 1 and Table 2 as well as the data set for Table 2. You'll need to install gologit2 and spost13 and change the data file location in the do file.

Suggested citations if using gologit2 in published work

gologit2 is not an official Stata command. It is a free contribution to the research community, like a paper. Please cite it as such. You can email Richard Williams if you do not otherwise have access to
these articles.

Williams, Richard. 2006. "Generalized Ordered Logit/ Partial Proportional Odds Models for Ordinal Dependent Variables." The Stata Journal 6(1):58-82. The published article is available for free at

Williams, Richard. 2016. 2016. "Understanding and interpreting generalized ordered logit models." The Journal of Mathematical Sociology, 40:1, 7-20.

Updates to the program that have been made since the 2006 Stata Journal article are summarized at

I would appreciate an email notification if you use gologit2 in published work, as well as a citation of  The Stata Journal and/or JMS papers listed above.  Also feel free to email me if you have comments about the program or its documentation.

Acknowledgements.  Vincent Kang Fu wrote gologit 1.0 and graciously allowed me to incorporate parts of its source code and documentation in gologit2.  The documentation for Stata 8.2's mlogit command and the program mlogit_p were major aids in developing the gologit2 documentation and in adding support for the predict command.  Much of the code is adapted from Maximum Likelihood Estimation with Stata, Second Edition, by William Gould, Jeffrey Pitblado and William Sribney.  Sarah Mustillo, Dan Powers, J. Scott Long, Nick Cox, Kit Baum and Joseph Hilbe have provided stimulating and helpful comments.

Related LinksFor examples of how to use Stata for a variety of tasks, see my Stata Highlights page.  The notes for my graduate statistics courses are on my Stats1 and Stats2 pages.  For more on categorical data analysis (including ordinal regression) see my notes for Sociology 73994