Abstract
The noncentral gamma distribution can be viewed as a generalization of the noncentral chi-squared distribution and it can be expressed as a mixture of a Poisson density function with a incomplete gamma function. The noncentral gamma distribution is not available in free conventional statistical programs. This paper aimed to propose an algorithm for the noncentral gamma by combining the method originally proposed by Benton and Krishnamoorthy (Comput Stat Data Anal 43(2):249–267, 2003) for the noncentral distributions with the method of inversion of the distribution function with respect to the noncentrality parameter using Newton–Raphson. The algorithms are available in pseudocode and implemented as R functions. To evaluate the accuracy and speed of computation of the algorithms implemented in R, results of the distribution function, density function, quantiles and noncentrality parameter of the noncentral incomplete gamma and its particular case, the noncentral chi-squared, were obtained for the arguments settings used by Benton and Krishnamoorthy (Comput Stat Data Anal 43(2):249–267, 2003) and Chen (J Stat Comput Simul 75(10):813–829, 2005). The implemented routines performed well and, in general, were as accurate than other approximations. The R package denoted ncg is available to download on the CRAN-R package repository http://cran.r-project.org/.
Similar content being viewed by others
References
Abramowitz M, Stegun IA (1970) Handbook of mathematical functions with formulas, graphs, and mathematical tables. Dover Publications, New York
Baharev A, Kemény S (2008) On the computation of the noncentral \(F\) and noncentral beta distribution. Stat Comput 18(3):333–340
Benton D, Krishnamoorthy K (2003) Computing discrete mixtures of continuous distributions: noncentral chisquare, noncentral \(t\) and the distribution of the square of the sample multiple correlation coefficient. Comput Stat Data Anal 43(2):249–267
Chen Z-Y (2005) The S-system computation of non-central gamma distribution. J Stat Comput Simul 75(10):813–829
Knüsel L, Bablok B (1996) Computation of the noncentral gamma distribution. SIAM J Sci Comput 17:1224–1231
Krishnamoorthy K (2006) Handbook of statistical distributions with applications. Chapman and Hall, Boca Raton, p 344
Maxima (2011) Maxima: a computer algebra system. http://maxima.sourceforge.net
R Development Core Team (2011) R: a language and environment for statistical computing. R Foundation for Statistical Computing, Vienna, Austria. http://www.R-project.org
Ruben H (1974) Non-central chi-square and gamma revisited. Commun Stat 3(7):607–633
Rust PF, Voit EO (1990) Statistical densities, cumulatives, quantiles, and power obtained by S-System differential equations. J Am Stat Assoc 85:572–578
\(\text{ SAS/STAT}^{\circledR}\) (2008) 9.2 Users guide. Version 9.2. SAS Institute Inc., Cary, 584p
Wang M, Kennedy WJ (1994) Self-validating computations of probabilities for selected central and non-central univariate probability functions. J Am Stat Assoc 89:878–887
Acknowledgments
The authors thank CNPq and Capes for the financial support.
Author information
Authors and Affiliations
Corresponding author
Rights and permissions
About this article
Cite this article
de Oliveira, I.R.C., Ferreira, D.F. Computing the noncentral gamma distribution, its inverse and the noncentrality parameter. Comput Stat 28, 1663–1680 (2013). https://doi.org/10.1007/s00180-012-0371-8
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00180-012-0371-8