Page 1 of 1

Bimodal/multimodal distribution of mixed logit random coefficients

Posted: 07 Oct 2023, 16:22
by Pea
Hi!

In Hess and Palma (2019) on page 15, it is shown how to make the random coefficients in a mixed logit follow a negative Lognormal distribution, a symmetrical Triangular distribution and a Johnson SB distribution, using Apollo. Is it also possible to make them follow a bimodal or multimodal distribution? How would that look?

Article:
Hess, S orcid.org/0000-0002-3650-2518 and Palma, D (2019) Apollo: A flexible, powerful
and customisable freeware package for choice model estimation and application. Journal
of Choice Modelling, 32 (100170). 100170. ISSN 1755-5345
https://doi.org/10.1016/j.jocm.2019.100170

Re: Bimodal/multimodal distribution of mixed logit random coefficients

Posted: 09 Oct 2023, 11:43
by stephanehess
Hi

as long as you can write your distribution as a transformation of normals or uniforms, you can do this inside apollo_randCoeff. So you can for example apply the SNP approach of https://doi.org/10.1016/j.econlet.2013.03.050 that way

Stephane

Re: Bimodal/multimodal distribution of mixed logit random coefficients

Posted: 13 Oct 2023, 12:08
by Pea
Hi Stephane

Thank you so much for responding. I'm afraid I've read the paper, but I don't seem to understand it well enough to be able to implement the approach in Apollo... You wouldn't happen to have a piece of code where the approach is used inside apollo_randCoeff, would you?

Best wishes
Pea

Re: Bimodal/multimodal distribution of mixed logit random coefficients

Posted: 18 Oct 2023, 06:55
by stephanehess
Hi

sure, this is an example with the square term added:

Code: Select all

randcoeff[["b_tt"]] = b_tt_mu + b_tt_sig * draws_tt + b_tt_sig2 * draws_tt^2 

Re: Bimodal/multimodal distribution of mixed logit random coefficients

Posted: 19 Oct 2023, 15:54
by Pea
Thank you so much, now it works.