Stats distributions fishersnedecorisf - CyrilB1531/lodestar GitHub Wiki

Home β€Ί Stats β€Ί Distribution tails

Distributions.FisherSnedecorIsf

The f with P(F > f) = p: the inverse of FisherSnedecorSf.

public static double FisherSnedecorIsf(double p, double numeratorDf, double denominatorDf)

Parameters β€” p is a probability in [0, 1]; 0 answers +∞ and 1 answers 0. numeratorDf and denominatorDf are the two degrees of freedom, each of which must be positive and finite.

Returns β€” scipy.stats.f.isf(p, dfn, dfd).

Exceptions β€” ArgumentOutOfRangeException when p is outside [0, 1], NaN included, or when either degrees of freedom is not positive. A df of 5e-324, whose half is not a double, is refused too (#1690).

Example β€” the same 5% critical value, read from the upper tail.

using Lodestar.Stats;

double critical = Distributions.FisherSnedecorIsf(0.05, 2.0, 20.0);   // => 3.492828…

Remarks β€” More exact than scipy's at small p. scipy.stats.f.isf(1e-8, 1, 1) is 5.0e-9 off in relative terms, measured against the closed form 1/tanΒ²(π·p/2) and against scipy's own sf; this one reproduces both to 4e-15.

Applies to β€” net10.0, netstandard2.0.

See also β€” Distributions.FisherSnedecorQuantile, Distributions.FisherSnedecorSf.