mixl: An open-source R package for estimating complex choice models on large datasets

https://doi.org/10.1016/j.jocm.2021.100284Get rights and content
Under a Creative Commons license
open access

Highlights

  • A new R package for mixed logit models and hybrid choice models.

  • Model specification syntax replicates the mathematical formulation of the models.

  • Excellent performance, minimal memory usage, and multi-core scalability.

Abstract

This paper introduces mixl, a new R package for the estimation of advanced choice models. The estimation of such models typically relies on simulation methods with a large number of random draws to obtain stable results. mixl uses inherent properties of the log-likelihood problem structure to greatly reduce both the memory usage and runtime of the estimation procedure for specific types of mixed multinomial logit models. Functions for prediction and posterior analysis are included. Parallel computing is also supported, with near linear speedups observed on up to 24 cores. mixl is directly accessible from R, available on CRAN. We show that mixl is fast, easy to use, and scales to very large datasets. This paper presents the architecture and performance of the package, details its use, and presents some results using real world data and models.

Keywords

Multinomial logit
Mixed logit
Choice modelling
R, hybrid choice
Estimation

Cited by (0)