Skip to content

Commit 2ab0aa3

Browse files
committed
fix: order validation checks by parameter position in stats/base/dists/cauchy/entropy
Reorder NaN guards so checks follow declaration order `(x0, gamma)`. Behavior unchanged: any matching branch returns `NaN`.
1 parent b06072e commit 2ab0aa3

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

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

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ var PI = require( '@stdlib/constants/float64/pi' );
4848
*/
4949
function entropy( x0, gamma ) {
5050
if (
51-
isnan( gamma ) ||
5251
isnan( x0 ) ||
52+
isnan( gamma ) ||
5353
gamma <= 0.0
5454
) {
5555
return NaN;

0 commit comments

Comments
 (0)