% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/random-tidy-bernoulli.R
\name{tidy_bernoulli}
\alias{tidy_bernoulli}
\title{Tidy Randomly Generated Bernoulli Distribution Tibble}
\usage{
tidy_bernoulli(.n = 50, .prob = 0.1, .num_sims = 1, .return_tibble = TRUE)
}
\arguments{
\item{.n}{The number of randomly generated points you want.}

\item{.prob}{The probability of success/failure.}

\item{.num_sims}{The number of randomly generated simulations you want.}

\item{.return_tibble}{A logical value indicating whether to return the result
as a tibble. Default is TRUE.}
}
\value{
A tibble of randomly generated data.
}
\description{
This function will generate \code{n} random points from a Bernoulli
distribution with a user provided, \code{.prob}, and number of random simulations
to be produced. The function returns a tibble with the simulation number
column the x column which corresponds to the n randomly generated points,
the \code{d_}, \code{p_} and \code{q_} data points as well.

The data is returned un-grouped.

The columns that are output are:
\itemize{
\item \code{sim_number} The current simulation number.
\item \code{x} The current value of \code{n} for the current simulation.
\item \code{y} The randomly generated data point.
\item \code{dx} The \code{x} value from the \code{\link[stats:density]{stats::density()}} function.
\item \code{dy} The \code{y} value from the \code{\link[stats:density]{stats::density()}} function.
\item \code{p} The values from the resulting p_ function of the distribution family.
\item \code{q} The values from the resulting q_ function of the distribution family.
}
}
\details{
This function uses the \code{rbinom()}, and its underlying
\code{p}, \code{d}, and \code{q} functions. The \emph{Bernoulli} distribution is a special case
of the \emph{Binomial} distribution with \code{size = 1} hence this is why the \code{binom}
functions are used and set to size = 1.
}
\examples{
tidy_bernoulli()
}
\seealso{
\url{https://en.wikipedia.org/wiki/Bernoulli_distribution}

Other Discrete Distribution: 
\code{\link{tidy_binomial}()},
\code{\link{tidy_hypergeometric}()},
\code{\link{tidy_negative_binomial}()},
\code{\link{tidy_poisson}()},
\code{\link{tidy_zero_truncated_binomial}()},
\code{\link{tidy_zero_truncated_negative_binomial}()},
\code{\link{tidy_zero_truncated_poisson}()}

Other Bernoulli: 
\code{\link{util_bernoulli_param_estimate}()},
\code{\link{util_bernoulli_stats_tbl}()}
}
\author{
Steven P. Sanderson II, MPH
}
\concept{Bernoulli}
\concept{Discrete Distribution}
