The multinomial distribution is an extension of the binomial to the situation where

the response can take more than two values. Let Yi be a random variable that takes

one of a finite number of values, 1,2, . . . ,J. Let pi j = P(Yi = j) so ∑ J j=1 pi j = 1.

As with binary data (the case where J = 2), we may encounter both grouped and ungrouped data. Let Yi j be the number of observations falling into category j for

group or individual i and let ni = ∑ jYi j. For ungrouped data, ni = 1 and one and only one of Yi1, . . . ,YiJ is equal to one and the rest are zero. The Yi j, conditional on the total ni, follow a multinomial distribution: