@stdlib/stats
Version:
Standard library statistical functions.
64 lines (48 loc) • 1.3 kB
Plain Text
{{alias}}( x, n )
Evaluates the cumulative distribution function (CDF) for the distribution of
the Wilcoxon signed rank test statistic with `n` observations.
If provided `NaN` as any argument, the function returns `NaN`.
If provided a negative value for `x`, the function returns `NaN`.
If not provided a positive integer for `n`, the function returns `NaN`.
Parameters
----------
x: number
Input value.
n: integer
Number of observations.
Returns
-------
out: number
Evaluated CDF.
Examples
--------
> var y = {{alias}}( 3, 7 )
~0.039
> y = {{alias}}( 1.8, 3 )
~0.375
> y = {{alias}}( -1.0, 40 )
0.0
> y = {{alias}}( NaN, 10 )
NaN
> y = {{alias}}( 0.0, NaN )
NaN
{{alias}}.factory( n )
Returns a function for evaluating the cumulative distribution function (CDF)
of the distribution of the Wilcoxon signed rank test statistic.
Parameters
----------
n: integer
Number of observations.
Returns
-------
cdf: Function
Cumulative distribution function (CDF).
Examples
--------
> var myCDF = {{alias}}.factory( 8 );
> var y = myCDF( 5.7 )
~0.055
> y = myCDF( 2.2 )
~0.012
See Also
--------