| Statistics Toolbox | Search  Help Desk |
| hygecdf | Examples |
Hypergeometric cumulative distribution function (cdf).
Syntax
P = hygecdf(X,M,K,N)
Description
hygecdf(X,M,K,N) computes the hypergeometric cdf with parameters M, K, and N at the values in X. The arguments X, M, K, and N must all be the same size except that scalar arguments function as constant matrices of the common size of the other arguments. The hypergeometric cdf is:
Examples
Suppose you have a lot of 100 floppy disks and you know that 20 of them are defective. What is the probability of drawing zero to two defective floppies if you select 10 at random?p = hygecdf(2,100,20,10)
p =
0.6812