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

◆ beta_rng()

template<typename T_shape1 , typename T_shape2 , class RNG >
VectorBuilder< true, double, T_shape1, T_shape2 >::type stan::math::beta_rng ( const T_shape1 &  alpha,
const T_shape2 &  beta,
RNG &  rng 
)
inline

Return a Beta random variate with the supplied success and failure parameters using the given random number generator.

alpha and beta can each be a scalar or a one-dimensional container. Any non-scalar inputs must be the same size.

Template Parameters
T_shape1type of success parameter
T_shape2type of failure parameter
RNGtype of random number generator
Parameters
alpha(Sequence of) positive finite success parameter(s)
beta(Sequence of) positive finite failure parameter(s)
rngrandom number generator
Returns
(Sequence of) beta random variate(s)
Exceptions
std::domain_errorif alpha or beta are nonpositive
std::invalid_argumentif non-scalar arguments are of different sizes

Definition at line 36 of file beta_rng.hpp.