Skip to content

Commit 91ef457

Browse files
authored
fix: provide correct stride index
Signed-off-by: Athan <[email protected]>
1 parent 9032249 commit 91ef457

File tree

1 file changed

+1
-1
lines changed
  • lib/node_modules/@stdlib/stats/base/max-by/lib

1 file changed

+1
-1
lines changed

lib/node_modules/@stdlib/stats/base/max-by/lib/ndarray.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ function maxBy( N, x, strideX, offsetX, clbk, thisArg ) {
6464
return accessors( N, o, strideX, offsetX, clbk, thisArg );
6565
}
6666
if ( N === 1 || strideX === 0 ) {
67-
v = clbk.call( thisArg, x[ offsetX ], 0, 0, x );
67+
v = clbk.call( thisArg, x[ offsetX ], 0, offsetX, x );
6868
if ( v === void 0 ) {
6969
return NaN;
7070
}

0 commit comments

Comments
 (0)