chi2P ( chi df -- p )


Vocabulary
math.extras

Inputs and outputs
chia real
dfa real
pa real


Word description
Returns the inverse chi-squared value according to P(chi|df) = P(df/2,chi/2).

Definition
USING: kernel math math.extras.private math.order ;

IN: math.extras

: chi2P ( chi df -- p )
dup df-check [ 2.0 / ] [ 2 /i ] bi* (chi2P) 1.0 min ;