echoice2 R Package

Articles From: Dr. Nino Hardt
Website: Dr. Nino Hardt

The echoice2 R package implements economic models of choice. This includes discrete choice and volumetric choice models with and without screening rules. These models can be used for analyzing data from choice experiments (aka conjoint analysis) or individual-level transaction data such as household-level panel data.

All models are “Hierarchical Bayes” models, and estimated using Markov chain Monte Carlo (MCMC). When available, OpenMP is used to parallelize the samplers. The source code prioritizes simplicity over elegance, and hopefully other authors of economic choice models can contribute to the package. The main motivation of this package is to make economic models of choice more accessible.

The foundations of economic choice models are described in the chapter “Economic foundations of conjoint analysis” (Allenby, Hard, Rossi, 2019) <doi:10.1016/bs.hem.2019.04.002>.  Economic models of choice comprise a microeconomic model of individual behavior, or stochastic specification and model of heterogeneity. Grounding models in theory matters when the primary purpose of an analysis is to counterfactualize.

Non-compensatory choice and screening is described in the paper “Conjunctive Screening in Models of Multiple Discreteness” (Kim, Hardt, Kim, Allenby, 2022) <doi:10.1016/j.ijresmar.2022.04.001>. The case of changing assortment size is discussed in “Volumetric Demand and Set Size Variation” (Hard,t Kurz, 2020) <doi:10.2139/ssrn.3418383>. The package might also be referenced in other upcoming publications. One of the package vignettes shows how to import data from the seminal “bayesm” https://cran.r-project.org/package=bayesm package.

echoice2 is available on CRAN https://CRAN.R-project.org/package=echoice2. Two vignettes demonstrate how to use the package to estimate models on conjoint-style data and generate predictions that could be used for “market” simulation:

Join the Discussion

Thank you for engaging with IBKR Campus. If you have a general question, it may already be covered in our FAQs. If you have an account-specific question or concern, please reach out to Client Services.

Your email address will not be published. Required fields are marked *

Disclosure: Interactive Brokers

Information posted on IBKR Campus that is provided by third-parties does NOT constitute a recommendation that you should contract for the services of that third party. Third-party participants who contribute to IBKR Campus are independent of Interactive Brokers and Interactive Brokers does not make any representations or warranties concerning the services offered, their past or future performance, or the accuracy of the information provided by the third party. Past performance is no guarantee of future results.

This material is from Dr. Nino Hardt and is being posted with its permission. The views expressed in this material are solely those of the author and/or Dr. Nino Hardt and Interactive Brokers is not endorsing or recommending any investment or trading discussed in the material. This material is not and should not be construed as an offer to buy or sell any security. It should not be construed as research or investment advice or a recommendation to buy, sell or hold any security or commodity. This material does not and is not intended to take into account the particular financial conditions, investment objectives or requirements of individual customers. Before acting on this material, you should consider whether it is suitable for your particular circumstances and, as necessary, seek professional advice.