There are some scenarios where we need to sample the distribution from discrete events like a coin toss result, the value of a dice roll, or the number of people.
Probability Mass Function (PMF)
The concept of CDF is the same for both continuous and discrete distributions, though PDF is replaced by the Probability Mass Function (PMF). Here we calculate the probability for a given sample directly instead of differentiation.
Poisson distribution is used to sample unlikely events (events with low probability).
Both expected value and mean will be the same:
We can sample a Poisson distribution through
poisson(key, <λ's value>, size) .