# Pois-class

From distr v2.0.2
by Peter Ruckdeschel

##### Class "Pois"

The Poisson distribution has density $$p(x) = \frac{\lambda^x e^{-\lambda}}{x!}$$
for $x = 0, 1, 2, \ldots$. The mean and variance are
$E(X) = Var(X) = \lambda$.
C.f. `rpois`

- Keywords
- distribution

##### Note

Working with a computer, we use a finite interval as support which carries at least mass `1-getdistrOption("TruncQuantile")`

.

##### Objects from the Class

Objects can be created by calls of the form `Pois(lambda)`

.
This object is a Poisson distribution.

##### Extends

Class `"DiscreteDistribution"`

, directly.
Class `"UnivariateDistribution"`

, by class `"DiscreteDistribution"`

.
Class `"Distribution"`

, by class `"DiscreteDistribution"`

.

##### concept

- discrete distribution
- lattice distribution
- Poisson distribution
- S4 parameter class
- generating function

##### See Also

`PoisParameter-class`

`DiscreteDistribution-class`

`Naturals-class`

`rpois`

##### Examples

```
P <- Pois(lambda = 1) # P is a Poisson distribution with lambda = 1.
r(P)(1) # one random number generated from this distribution, e.g. 1
d(P)(1) # Density of this distribution is 0.3678794 for x = 1.
p(P)(0.4) # Probability that x < 0.4 is 0.3678794.
q(P)(.1) # x = 0 is the smallest value x such that p(B)(x) >= 0.1.
lambda(P) # lambda of this distribution is 1.
lambda(P) <- 2 # lambda of this distribution is now 2.
R <- Pois(lambda = 3) # R is a Poisson distribution with lambda = 2.
S <- P + R # R is a Poisson distribution with lambda = 5(=2+3).
```

*Documentation reproduced from package distr, version 2.0.2, License: LGPL-3*

### Community examples

Looks like there are no examples yet.