Poisson | R Documentation |
Poisson distributions are frequently used to model counts.
Poisson(lambda)
lambda |
The shape parameter, which is also the mean and the variance of the distribution. Can be any positive number. |
We recommend reading this documentation on https://alexpghayes.github.io/distributions3/, where the math will render with additional detail.
In the following, let X
be a Poisson random variable with parameter
lambda
= \lambda
.
Support: \{0, 1, 2, 3, ...\}
Mean: \lambda
Variance: \lambda
Probability mass function (p.m.f):
P(X = k) = \frac{\lambda^k e^{-\lambda}}{k!}
Cumulative distribution function (c.d.f):
P(X \le k) = e^{-\lambda}
\sum_{i = 0}^{\lfloor k \rfloor} \frac{\lambda^i}{i!}
Moment generating function (m.g.f):
E(e^{tX}) = e^{\lambda (e^t - 1)}
A Poisson
object.
Other discrete distributions:
Bernoulli()
,
Binomial()
,
Categorical()
,
Geometric()
,
HurdleNegativeBinomial()
,
HurdlePoisson()
,
HyperGeometric()
,
Multinomial()
,
NegativeBinomial()
,
PoissonBinomial()
,
ZINegativeBinomial()
,
ZIPoisson()
,
ZTNegativeBinomial()
,
ZTPoisson()
set.seed(27)
X <- Poisson(2)
X
random(X, 10)
pdf(X, 2)
log_pdf(X, 2)
cdf(X, 4)
quantile(X, 0.7)
cdf(X, quantile(X, 0.7))
quantile(X, cdf(X, 7))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.