timjmiller / wham

State-space, age-structured fish stock assessment model
https://timjmiller.github.io/wham
Other
32 stars 16 forks source link

Bug in `rdirmultinom` #53

Closed James-Thorson-NOAA closed 2 years ago

James-Thorson-NOAA commented 2 years ago

I'm exploring a cross-test of the DirMult and a new distribution for self-weighting comps. I'm starting with a self-test of the DirMult, and initially got weird results. I think the reason is a bug in the rdirmultinom function, which should simulate a single draw from the Dirichlet for all samples from the multinomial, not a separate draw for each sample.

Do you want me to do a PR on the main or devel branch, or perhaps have some further discussion here first?

timjmiller commented 2 years ago

This is a duplicate of #49. It has been corrected on devel branch.