Skip to content

Commit 4f23ca4

Browse files
committed
fix: order validation checks by parameter position in stats/base/dists/cauchy/quantile
Move `isnan( p )` to the front so the validation prologue follows declaration order `(p, x0, gamma)`. Supersedes the prior majority-vote ordering on this branch. Behavior unchanged: any matching branch returns `NaN`.
1 parent c5a494e commit 4f23ca4

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • lib/node_modules/@stdlib/stats/base/dists/cauchy/quantile/lib

lib/node_modules/@stdlib/stats/base/dists/cauchy/quantile/lib/main.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,10 @@ var PI = require( '@stdlib/constants/float64/pi' );
7474
*/
7575
function quantile( p, x0, gamma ) {
7676
if (
77-
isnan( gamma ) ||
77+
isnan( p ) ||
7878
isnan( x0 ) ||
79+
isnan( gamma ) ||
7980
gamma <= 0.0 ||
80-
isnan( p ) ||
8181
p < 0.0 ||
8282
p > 1.0
8383
) {

0 commit comments

Comments
 (0)