Automatic Differentiation
 
Loading...
Searching...
No Matches

◆ multinomial_logit_rng()

template<class RNG , typename T_beta , require_eigen_col_vector_t< T_beta > * = nullptr>
std::vector< int > stan::math::multinomial_logit_rng ( const T_beta &  beta,
int  N,
RNG &  rng 
)
inline

Return a draw from a Multinomial distribution given a vector of unnormalized log probabilities, a total count, and a pseudo-random number generator.

Template Parameters
RNGType of pseudo-random number generator.
Parameters
betaVector of unnormalized log probabilities.
NTotal count.
rngPseudo-random number generator.
Returns
Multinomial random variate.
Exceptions
std::domain_errorif any element of beta is not finite.
std::domain_erroris N is less than 0.

Definition at line 29 of file multinomial_logit_rng.hpp.