返回超几何分布。 如果已知样本量、总体成功次数和总体大小,则 HYPGEOMDIST 返回样本取得已知成功次数的概率。 HYPGEOMDIST 用于处理以下的有限总体问题,在该有限总体中,每次观察结果或为成功或为失败,并且已知样本量的每个子集的选取是等可能的。
语法
HYPGEOMDIST (sample_s,number_sample,population_s,number_population)
Sample_s 是示例中的成功次数。
Number_sample 是样本的大小。
Population_s 是总体的成功次数。
Number_population 是总体大小。
备注
- 所有参数都将被截尾取整。
- 如果任一参数为非数值型,则 HYPGEOMDIST 返回 #VALUE! 。
- 如果sample_s < 0 或 sample_s 大于小于 number_sample 或 population_s,则 HYPGEOMDIST 返回 #NUM! 。
- 如果 sample_s 小于 0 和 (number_sample - number_population + population_s) 中的较大值,则 HYPGEOMDIST 返回 #NUM! 。
- 如果 number_sample < 0 或 number_sample > number_population,则 HYPGEOMDIST 返回 #NUM! 错误值。
- 如果population_s < 0 或 population_s > number_population,则 HYPGEOMDIST 返回 #NUM! 错误值。
- 如果number_population < 0,则 HYPGEOMDIST 返回 #NUM! 。
- 超几何分布的公式为:
其中:
x = sample_s
n = number_sample
M = population_s
N = number_population
HYPGEOMDIST 用于有限总体中的不放回抽样。
示例
巧克力采样器包含 20 件。 8件是焦糖,其余12件是坚果。 如果一个人随机选择 4 件,以下函数将返回恰好 1 件是焦糖的概率。
| Sample_s | Number_sample | Population_s | Number_Population | 公式 | 描述(结果) |
|---|---|---|---|---|---|
| 1 | 4 | 8 | 20 | =HYPGEOMDIST ([Sample_s],[Number_sample],[Population_s],[Number_Population]) | 样本和总体的超几何分布 (0.363261) |