Efficient way to draw multinomial distribution random samples

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Efficient way to draw multinomial distribution random samples

Currurant
I realized that neither numpy.random.multinomial nor rng.multinomial has the
ability to draw from different multinomial distributions at the same time
like what MATLAB mnrnd() does here:

https://www.mathworks.com/help/stats/mnrnd.html

Also, I have asked this question on StackOverFlow:

https://stackoverflow.com/questions/64529620/is-there-an-efficient-way-to-generate-multinomial-random-variables-in-parallel?noredirect=1#comment114131565_64529620

It seems like this is something good to add to numpy.random, since it would
be much more faster when you have many multinomial distributions to draw
from---using loops.



--
Sent from: http://numpy-discussion.10968.n7.nabble.com/
_______________________________________________
NumPy-Discussion mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/numpy-discussion
Reply | Threaded
Open this post in threaded view
|

Re: Efficient way to draw multinomial distribution random samples

bashtage
This is in the pending PR.  Hopefully out in 1.20.  

Kevin


On Sun, Nov 1, 2020, 23:55 Currurant <[hidden email]> wrote:
I realized that neither numpy.random.multinomial nor rng.multinomial has the
ability to draw from different multinomial distributions at the same time
like what MATLAB mnrnd() does here:

https://www.mathworks.com/help/stats/mnrnd.html

Also, I have asked this question on StackOverFlow:

https://stackoverflow.com/questions/64529620/is-there-an-efficient-way-to-generate-multinomial-random-variables-in-parallel?noredirect=1#comment114131565_64529620

It seems like this is something good to add to numpy.random, since it would
be much more faster when you have many multinomial distributions to draw
from---using loops.



--
Sent from: http://numpy-discussion.10968.n7.nabble.com/
_______________________________________________
NumPy-Discussion mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/numpy-discussion

_______________________________________________
NumPy-Discussion mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/numpy-discussion