RSGHB: Functions for Hierarchical Bayesian Estimation: A Flexible Approach

This package can be used to estimate models using a hierarchical Bayesian framework. The flexibility comes in allowing the user to specify the likelihood function directly instead of assuming predetermined model structures. Types of models that can be estimated with this code include the family of discrete choice models (Multinomial Logit, Mixed Logit, Nested Logit, Error Components Logit and Latent Class) as well ordered response models like ordered probit and ordered logit. In addition, the package allows for flexibility in specifying parameters as either fixed (non-varying across individuals) or random with continuous distributions. Parameter distributions supported include normal, positive log-normal, negative log-normal, positive truncated normal and the Johnson SB distribution. Kenneth Train's Matlab and Gauss code for doing hierarchical Bayesian estimation has served as the basis for a few of the functions included in this package. These Matlab/Gauss functions have been rewritten to be optimized within R. Considerable code has been added to increase the flexibility and usability of the code base. Train's original Gauss and Matlab code can be found here: See Train's chapter on HB in Discrete Choice with Simulation here:; and his paper on using HB with non-normal distributions here:

Version: 1.0.1
Published: 2013-04-10
Author: Jeff Dumont, Jeff Keller, Chase Carpenter
Maintainer: Jeff Dumont <Jeff.Dumont at>
License: GPL-3
NeedsCompilation: yes
In views: Bayesian, Bayesian, Econometrics
CRAN checks: RSGHB results


Reference manual: RSGHB.pdf
Vignettes: How to use RSGHB
Package source: RSGHB_1.0.1.tar.gz
MacOS X binary: RSGHB_1.0.1.tgz
Windows binary:
Old sources: RSGHB archive