Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Multinomial distribution
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Random variate generation === {{further|Non-uniform random variate generation}} First, reorder the parameters <math>p_1, \ldots, p_k</math> such that they are sorted in descending order (this is only to speed up computation and not strictly necessary). Now, for each trial, draw an auxiliary variable ''X'' from a uniform (0, 1) distribution. The resulting outcome is the component : <math>j = \min \left\{ j' \in \{1,\dots,k\}\colon \left(\sum_{i=1}^{j'} p_i\right) - X \geq 0 \right\}.</math> {''X''<sub>''j''</sub> = 1, ''X''<sub>''k''</sub> = 0 for ''k'' β ''j'' } is one observation from the multinomial distribution with <math>p_1, \ldots, p_k</math> and ''n'' = 1. A sum of independent repetitions of this experiment is an observation from a multinomial distribution with ''n'' equal to the number of such repetitions.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)