The OpenD Programming Language

KurtosisAlgo

Kurtosis algorithms.

Values

ValueMeaning
online

Similar to Welford's algorithm for updating variance, but adjusted for kurtosis. Can also put another KurtosisAccumulator of the same type, which uses the parallel algorithm from Terriberry that extends the work of Chan et al.

naive

Calculates kurtosis using (E(x^^4) - 4 * E(x) * E(x ^^ 3) + 6 * (E(x) ^^ 2) E(X ^^ 2) + 3 E(x) ^^ 4) / sigma ^ 2 (allowing for adjustments for population/sample kurtosis).

This algorithm can be numerically unstable.

twoPass

Calculates kurtosis by first calculating the mean, then calculating E((x - E(x)) ^^ 4) / (E((x - E(x)) ^^ 2) ^^ 2)

threePass

Calculates kurtosis by first calculating the mean, then the standard deviation, then calculating E(((x - E(x)) / (E((x - E(x)) ^^ 2) ^^ 0.5)) ^^ 4)

assumeZeroMean

Calculates kurtosis assuming the mean of the input is zero.

hybrid

When slices, slice-like objects, or ranges are the inputs, uses the two-pass algorithm. When an individual data-point is added, uses the online algorithm.

See Also

Meta