目录

  • 1 概率论的基本概念
    • 1.1 随机试验
    • 1.2 样本空间、随机事件
    • 1.3 频率与概率
    • 1.4 等可能概型(古典概型)
    • 1.5 条件概率
    • 1.6 独立性
  • 2 随机变量及其分布
    • 2.1 随机变量
    • 2.2 离散型随机变量及其分布
    • 2.3 随机变量的分布函数
    • 2.4 连续型随机变量及其概率密度
    • 2.5 随机变量的函数的分布
  • 3 多维随机变量及其分布
    • 3.1 二维随机变量
    • 3.2 边缘分布
    • 3.3 新建目录
    • 3.4 新建目录
    • 3.5 二维随机变量的特征数
  • 4 随机变量的数字特征
    • 4.1 数学期望
    • 4.2 随机变量的数字特征
    • 4.3 协方差及相关系数
    • 4.4 矩、协方差矩阵
  • 5 大数定律与中心极限定理
    • 5.1 大数定律
    • 5.2 中心极限定理
  • 6 统计量及其分布
    • 6.1 样本数据的整理与显示
    • 6.2 统计量及其分布
  • 7 参数估计
    • 7.1 点估计得几种方法
    • 7.2 点估计的评价标准
    • 7.3 区间估计
  • 8 假设检验
    • 8.1 假设检验的基本思想与概念
    • 8.2 正态总体参数假设检验
  • 9 基于R语言的实验
    • 9.1 R语言介绍
    • 9.2 R软件下载与安装
    • 9.3 初识R软件
    • 9.4 蒲丰投针的计算
    • 9.5 同一天生日的计算
    • 9.6 抛硬币和骰子
    • 9.7 两点分布
    • 9.8 二项分布
    • 9.9 泊松分布
    • 9.10 正态分布
    • 9.11 指数分布
泊松分布

9.9 The Poisson Distribution

The Poisson distribution is a discrete distribution which was designed to count the number of events that occur in a particular time interval. A common (approximate) example is counting the number of customers who enter a bank in a particular hour. We traditionally call the expected number of occurrences λ or lambda.


Poisson vs. binomial: The key difference between the Poisson and the binomial is that for the binomial, the total number of trials in the sample is fixed, while for the Poisson, the total number of events in the interval is not fixed. That said, the binomial distribution begins to look a lot like the Poisson distribution when the number of trials grows large, and the probability of success is small.


Random Samples: rpois

As with the binomial, we can easily sample from the Poisson using the rpois() function, which now take takes two arguments:

  • n: how many outcomes we want to sample

  • lambda: the expected number of events per interval

rpois(n = 10, lambda = 14)
##  [1] 12 14 18 13  9 13 10 17 20  8

We can also plot a much larger sample of outcomes from this lambda = 14 Poisson distribution,

data = rpois(n = 1000, lambda = 14)
barplot(table(data))

Density Functions: dpois

The probability density function (PDF) of the Poisson distribution is given by:f(x|λ)=Pr(X=x)=λxexx!where e is equal to 2.7182818 and ! is the factorial operator.

The function that computes this automatically is dpois(). The d stands for “density” and the pois stands for “Poisson”. Suppose we want to know the probability of getting 12 occurrences, we can get this easily with,

dpois(x = 12, lambda = 14)
## [1] 0.09841849

As before, we can easily obtain and graph the main part of the distribution,

barplot(height = dpois(0:30, lambda = 14), 
        names.arg = 0:30,
        main = "Poisson PDF", xlab = 'X', ylab = 'Probability')

Note that this looks very much like the shape of the binomial distribution from the previous example. This is no coincidence, since the binomial(20, 0.7) and the Poisson(14) distributions are closely related (note that 200.7=14).

Cumulative Distribution Functions: ppois

The cumulative distribution function (CDF) of the Poisson distribution is given by:F(q|λ)=Pr(Xq)=k=0qf(k|λ)

Suppose we want to know the probability of getting at most 12 occurrences, we can get this easily with,

ppois(q = 12, lambda = 14)
## [1] 0.3584584

As before, we can easily obtain and graph the main part of the CDF,

barplot(height = ppois(0:30, lambda = 14), 
        names.arg = 0:30,
        main = "Poisson CDF", xlab = 'X', ylab = 'Probability')