Alex Herbert created STATISTICS-39:
--------------------------------------
Summary: Correct the switch of function evaluation in the
GammaDistribution
Key: STATISTICS-39
URL: https://issues.apache.org/jira/browse/STATISTICS-39
Project: Apache Commons Statistics
Issue Type: Improvement
Components: distribution
Affects Versions: 1.0
Reporter: Alex Herbert
The Gamma distribution density is not accurate when shape < 1. There are
extensive tests related to MATH-753 [7] for accuracy of the Gamma distribution.
These test shape >= 1. The work requires extension to smaller shapes where the
density -> infinite as X -> 0. When shape >= 1 then density -> 0 as X -> 0 (see
[https://en.wikipedia.org/wiki/Gamma_distribution]).
This results in inaccuracy of the Chi-squared distribution which uses
Gamma(df/2, 2) when the degrees of freedom (df) are < 2. I've read the code and
the documentation for the Boost functions which the code is based on and I
think the switch to the alternative computation to avoid overflow is currently
not working for all cases.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)