Categories &

Functions List

Function Reference: hygestat

statistics: [mn, v] = hygestat (m, k, n)

Compute statistics of the hypergeometric distribution.

[mn, v] = hygestat (m, k, n) returns the mean and variance of the hypergeometric distribution parameters m, k, and n.

  • m is the total size of the population of the hypergeometric distribution. The elements of m must be non-negative integers.
  • k is the number of marked items of the hypergeometric distribution. The elements of k must be natural numbers.
  • n is the size of the drawn sample of the hypergeometric distribution. The elements of n must be non-negative integers.

A sample of size 0 contains no marked items, so its mean and variance are 0, even for an empty population, where MATLAB returns NaN for both. A sample from a population of one always holds the same number of marked items, so its variance is 0, where MATLAB returns NaN.

The size of mn (mean) and v (variance) is the common size of the input arguments. A scalar input functions as a constant matrix of the same size as the other inputs.

Further information about the hypergeometric distribution can be found at https://en.wikipedia.org/wiki/Hypergeometric_distribution

See also: hygecdf, hygeinv, hygepdf, hygernd

Source Code: hygestat