Create a ddf object for the Bernoulli distribution with the given
parameters.
Details
The Bernoulli distribution with success probability \(p\) only has the two elements \(0\) and \(1\) as its support with the corresponding probability mass function being given by $$p(k) = \begin{cases} p & \text{if } k = 1,\\ 1-p & \text{if } k = 0. \end{cases}$$ Hence, it can be used to model experiments asking a single yes-no question or experiments whose only outcomes are "success" and "failure".
See also
Other distributions:
benford(),
beta_binomial(),
bin(),
geometric(),
hypergeometric(),
negative_bin(),
negative_hypergeometric(),
pois(),
rademacher(),
unif(),
zipf()
