Maybe Not Completely Redundant Message #7 Posted by Les Wright on 5 Dec 2011, 8:47 a.m., in response to message #2 by Paul Dale
Actually, the wp34s provides only the lower regularized incomplete gamma and cdf's (lower tail) for phi and chisquare.
But what if one wants high precision in the upper tail of the regularized incomplete gamma or its specific relatives? For phi it's easy, since the symmetry of the standard normal distribution means that 1  phi(x) = phi(x), so if I want the uppertail probability associated with the normal statistic x = 3 I would compute phi(3) instead.
But there is no such reflection relation for chisquare. A highvalue of the statistic will give a probability close to one, and digits (and precision) will be lost due to subtraction from 1 to get the complementary uppertail probability. It is probably better to compute the uppertail chisquare probability by way of the underlying continued fraction expansion for the rightsided incomplete gammaIGL in my program. Of course, this only matters if one really cares about the lost digits. In practical applications, most likely wouldn't.
I notice the builtin erfc function gives all or almost all 16 digits accurate for higher values of the argument in cases where subtracting erf from 1 would give zero. I am surmising that erfc has it's own routine and is not derived from the builtin regularized incomplete gamma.
