docs
docs copied to clipboard
Functions Refernce: return type of `bernoulli_rng` - `R` or `ints`?
Summary:
The bernoulli_rng function - https://mc-stan.org/docs/functions-reference/binary_distributions.html#bernoulli-distribution
has return type R:
R bernoulli_rng(reals theta)
Shouldn't this be ints?
Description:
Description: https://mc-stan.org/docs/functions-reference/conventions_for_probability_functions.html#return-type
Discrete distributions return ints and continuous distributions return reals, each of appropriate size. The symbol R denotes such a return type.
What about binary distributions?
Shouldn't this be ints?
Yes. It will be int if theta is real and int[] if theta is a one-dimensional array, vector, or row vector.