dbern: The Bernoulli distribution

Description Usage Arguments See Also

View source: R/dbern.R

Description

Density, distribution function, quantile function and random generation for the Bernoulli distribution.

Usage

1
2
3
4
5
6
7
dbern(x, prob, log = FALSE)

qbern(p, prob, lower.tail = TRUE, log.p = FALSE)

pbern(q, prob, lower.tail = TRUE, log.p = FALSE)

rbern(n, prob)

Arguments

x

numeric. Vector of quantiles.

prob

Probability of success on each trial.

log

logical. If TRUE, probabilities p are given as log(p).

p

numeric in [0, 1]. Vector of probabilities.

lower.tail

logical. If TRUE (default), probabilities are P[X <= x], otherwise, P[X > x].

log.p

logical. If TRUE, probabilities p are given as log(p).

q

numeric. Vector of quantiles.

n

number of observations. If length(n) > 1, the length is taken to be the number required.

See Also

See the help page of the Binomial distribution.


statip documentation built on Nov. 18, 2019, 1:06 a.m.