Stan Math Library
4.9.0
Automatic Differentiation
|
return_type_t< T_prob_cl > stan::math::binomial_lpmf | ( | const T_n_cl & | n, |
const T_N_cl | N, | ||
const T_prob_cl & | theta | ||
) |
Returns the log PMF for the binomial distribution evaluated at the specified success, population size, and chance of success.
If given containers of matching lengths, returns the log sum of probabilities.
T_n_cl | type of successes parameter |
T_N_cl | type of population size parameter |
T_prob_cl | type of chance of success parameter |
n | successes parameter |
N | population size parameter |
theta | chance of success parameter |
std::domain_error | if n is negative or greater than N |
std::domain_error | if N is negative |
std::domain_error | if theta is not a valid probability |
std::invalid_argument | if container sizes mismatch |
Definition at line 36 of file binomial_lpmf.hpp.