@stdlib/blas-ext-base-ndarray-snansumkbn 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -162,6 +162,11 @@ For more information on the project, filing bug reports and feature requests, an
162
162
 
163
163
  ---
164
164
 
165
+ ## License
166
+
167
+ See [LICENSE][stdlib-license].
168
+
169
+
165
170
  ## Copyright
166
171
 
167
172
  Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
@@ -177,8 +182,8 @@ Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
177
182
  [npm-image]: http://img.shields.io/npm/v/@stdlib/blas-ext-base-ndarray-snansumkbn.svg
178
183
  [npm-url]: https://npmjs.org/package/@stdlib/blas-ext-base-ndarray-snansumkbn
179
184
 
180
- [test-image]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/actions/workflows/test.yml/badge.svg?branch=v0.1.0
181
- [test-url]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/actions/workflows/test.yml?query=branch:v0.1.0
185
+ [test-image]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/actions/workflows/test.yml/badge.svg?branch=v0.1.1
186
+ [test-url]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/actions/workflows/test.yml?query=branch:v0.1.1
182
187
 
183
188
  [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/blas-ext-base-ndarray-snansumkbn/main.svg
184
189
  [coverage-url]: https://codecov.io/github/stdlib-js/blas-ext-base-ndarray-snansumkbn?branch=main
@@ -208,6 +213,8 @@ Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
208
213
  [esm-readme]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/blob/esm/README.md
209
214
  [branches-url]: https://github.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/blob/main/branches.md
210
215
 
216
+ [stdlib-license]: https://raw.githubusercontent.com/stdlib-js/blas-ext-base-ndarray-snansumkbn/main/LICENSE
217
+
211
218
  [@neumaier:1974a]: https://doi.org/10.1002/zamm.19740540106
212
219
 
213
220
  </section>
package/dist/index.js CHANGED
@@ -1,29 +1,5 @@
1
+ "use strict";var a=function(e,r){return function(){return r||e((r={exports:{}}).exports,r),r.exports}};var i=a(function(c,t){
2
+ var u=require('@stdlib/ndarray-base-numel-dimension/dist'),n=require('@stdlib/ndarray-base-stride/dist'),s=require('@stdlib/ndarray-base-offset/dist'),v=require('@stdlib/ndarray-base-data-buffer/dist'),q=require('@stdlib/blas-ext-base-snansumkbn/dist').ndarray;function d(e){var r=e[0];return q(u(r,0),v(r),n(r,0),s(r))}t.exports=d
3
+ });var m=i();module.exports=m;
1
4
  /** @license Apache-2.0 */
2
-
3
- 'use strict';
4
-
5
- /**
6
- * Compute the sum of a one-dimensional single-precision floating-point ndarray, ignoring `NaN` values and using an improved Kahan–Babuška algorithm.
7
- *
8
- * @module @stdlib/blas-ext-base-ndarray-snansumkbn
9
- *
10
- * @example
11
- * var Float32Array = require( '@stdlib/array-float32' );
12
- * var ndarray = require( '@stdlib/ndarray-base-ctor' );
13
- * var snansumkbn = require( '@stdlib/blas-ext-base-ndarray-snansumkbn' );
14
- *
15
- * var xbuf = new Float32Array( [ 1.0, -2.0, NaN, 2.0 ] );
16
- * var x = new ndarray( 'float32', xbuf, [ 4 ], [ 1 ], 0, 'row-major' );
17
- *
18
- * var v = snansumkbn( [ x ] );
19
- * // returns 1.0
20
- */
21
-
22
- // MODULES //
23
-
24
- var main = require( './main.js' );
25
-
26
-
27
- // EXPORTS //
28
-
29
- module.exports = main;
5
+ //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stdlib/blas-ext-base-ndarray-snansumkbn",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Compute the sum of a one-dimensional single-precision floating-point ndarray, ignoring `NaN` values and using an improved Kahan–Babuška algorithm.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -30,10 +30,10 @@
30
30
  "url": "https://github.com/stdlib-js/stdlib/issues"
31
31
  },
32
32
  "dependencies": {
33
- "@stdlib/blas-ext-base-snansumkbn": "^0.3.0",
34
- "@stdlib/ndarray-base-data-buffer": "^0.2.2",
33
+ "@stdlib/blas-ext-base-snansumkbn": "^0.3.1",
34
+ "@stdlib/ndarray-base-data-buffer": "^0.2.3",
35
35
  "@stdlib/ndarray-base-numel-dimension": "^0.3.2",
36
- "@stdlib/ndarray-base-offset": "^0.2.2",
36
+ "@stdlib/ndarray-base-offset": "^0.2.3",
37
37
  "@stdlib/ndarray-base-stride": "^0.2.2"
38
38
  },
39
39
  "devDependencies": {},
package/dist/main.js DELETED
@@ -1,56 +0,0 @@
1
- /**
2
- * @license Apache-2.0
3
- *
4
- * Copyright (c) 2025 The Stdlib Authors.
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
-
19
- 'use strict';
20
-
21
- // MODULES //
22
-
23
- var numelDimension = require( '@stdlib/ndarray-base-numel-dimension' );
24
- var getStride = require( '@stdlib/ndarray-base-stride' );
25
- var getOffset = require( '@stdlib/ndarray-base-offset' );
26
- var getData = require( '@stdlib/ndarray-base-data-buffer' );
27
- var strided = require( '@stdlib/blas-ext-base-snansumkbn' ).ndarray;
28
-
29
-
30
- // MAIN //
31
-
32
- /**
33
- * Computes the sum of a one-dimensional single-precision floating-point ndarray, ignoring `NaN` values and using an improved Kahan–Babuška algorithm.
34
- *
35
- * @param {ArrayLikeObject<Object>} arrays - array-like object containing an input ndarray
36
- * @returns {number} sum
37
- *
38
- * @example
39
- * var Float32Array = require( '@stdlib/array-float32' );
40
- * var ndarray = require( '@stdlib/ndarray-base-ctor' );
41
- *
42
- * var xbuf = new Float32Array( [ 1.0, -2.0, NaN, 2.0 ] );
43
- * var x = new ndarray( 'float32', xbuf, [ 4 ], [ 1 ], 0, 'row-major' );
44
- *
45
- * var v = snansumkbn( [ x ] );
46
- * // returns 1.0
47
- */
48
- function snansumkbn( arrays ) {
49
- var x = arrays[ 0 ];
50
- return strided( numelDimension( x, 0 ), getData( x ), getStride( x, 0 ), getOffset( x ) ); // eslint-disable-line max-len
51
- }
52
-
53
-
54
- // EXPORTS //
55
-
56
- module.exports = snansumkbn;