There is also a nag_gamma function. The gamma function is related to the factorial function, Gamma(N) = (N-1)! But N doesn't need to be an integer for the gamma function. It can any real number or complex number. But, the absolute value can't be larger than some value (Help does not indicate what value, but it's probably something like 162).