Skip to content

Commit cd9de64

Browse files
committed
Auto-generated commit
1 parent 747498b commit cd9de64

7 files changed

Lines changed: 20 additions & 67 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212

1313
- [`626f31e`](https://github.com/stdlib-js/stdlib/commit/626f31e5f7aa40d0dc64f48fa3b9c4f87f9bf30c) - update `ndarray/base` TypeScript declarations [(#9386)](https://github.com/stdlib-js/stdlib/pull/9386)
1414
- [`48c3c32`](https://github.com/stdlib-js/stdlib/commit/48c3c32ed78e8cad7b2719f2b2a0328a66e1c9e3) - add `ndarray/unshift` [(#9066)](https://github.com/stdlib-js/stdlib/pull/9066)
15+
- [`fdd3aa1`](https://github.com/stdlib-js/stdlib/commit/fdd3aa1bd398edec9c30a05569b05a3aba1897ec) - update `ndarray` TypeScript declarations [(#9335)](https://github.com/stdlib-js/stdlib/pull/9335)
1516
- [`2e0f8e6`](https://github.com/stdlib-js/stdlib/commit/2e0f8e6476ccc5194c02d472a327fb8a425fdfae) - add `ndarray/push` [(#9054)](https://github.com/stdlib-js/stdlib/pull/9054)
1617
- [`3feb022`](https://github.com/stdlib-js/stdlib/commit/3feb02271d5335920ebbd4ca0268f0a24340e168) - add `ndarray/flatten-from-by` [(#9040)](https://github.com/stdlib-js/stdlib/pull/9040)
1718
- [`d360fe5`](https://github.com/stdlib-js/stdlib/commit/d360fe525de98bfac66993c5c54b13fffccab822) - add `ndarray/base/to-reversed-dimension` [(#8852)](https://github.com/stdlib-js/stdlib/pull/8852)
@@ -617,6 +618,7 @@
617618

618619
- To migrate, users should be explicit in terms of whether a writable or read-only ndarray is returned. The previous behavior only returned a read-only array when provided a read-only array. The responsibility for determining the appropriate return value behavior is now pushed to userland.
619620

621+
- [`fdd3aa1`](https://github.com/stdlib-js/stdlib/commit/fdd3aa1bd398edec9c30a05569b05a3aba1897ec): update `ndarray` TypeScript declarations
620622
- [`b760fb5`](https://github.com/stdlib-js/stdlib/commit/b760fb5724fb36fb9ae5b18aaf642b3f25037cec): rename `sentinelValue` option to `sentinel`
621623

622624
- To migrate, users should update their usage of `sentinelValue` to use just `sentinel`.
@@ -665,6 +667,7 @@ A total of 37 issues were closed in this release:
665667

666668
<details>
667669

670+
- [`45264d0`](https://github.com/stdlib-js/stdlib/commit/45264d0387509a18856c21c332349f16c8a81086) - **docs:** improve doctests for ndarray instances in `ndarray/some` [(#9388)](https://github.com/stdlib-js/stdlib/pull/9388) _(by kaushal-kumar-it, Athan Reines)_
668671
- [`626f31e`](https://github.com/stdlib-js/stdlib/commit/626f31e5f7aa40d0dc64f48fa3b9c4f87f9bf30c) - **feat:** update `ndarray/base` TypeScript declarations [(#9386)](https://github.com/stdlib-js/stdlib/pull/9386) _(by stdlib-bot)_
669672
- [`345c740`](https://github.com/stdlib-js/stdlib/commit/345c7404530f8c5ba7215bfe6e25cc5e4a0af640) - **docs:** improve doctests for ndarray instances in `ndarray/count-falsy` [(#9377)](https://github.com/stdlib-js/stdlib/pull/9377) _(by kaushal-kumar-it)_
670673
- [`daf2cc8`](https://github.com/stdlib-js/stdlib/commit/daf2cc847c77117f4c5ae4e5e99ae224bb592edc) - **refactor:** add writable parameter to `ndarray/base/spread-dimensions` [(#9370)](https://github.com/stdlib-js/stdlib/pull/9370) _(by Muhammad Haris, Athan Reines)_
@@ -674,7 +677,7 @@ A total of 37 issues were closed in this release:
674677
- [`eaa7afb`](https://github.com/stdlib-js/stdlib/commit/eaa7afbbf6ea6499654b0f14ecbb7d59c0bf0d91) - **docs:** improve doctests for ndarray instances in `ndarray/any` [(#9345)](https://github.com/stdlib-js/stdlib/pull/9345) _(by DivitJain26)_
675678
- [`13dc3be`](https://github.com/stdlib-js/stdlib/commit/13dc3be658a96c61efecced1b0639f63081cf67d) - **docs:** improve doctests for ndarray instances in `ndarray/count-if` [(#9339)](https://github.com/stdlib-js/stdlib/pull/9339) _(by Lokesh Ranjan)_
676679
- [`32cb1a3`](https://github.com/stdlib-js/stdlib/commit/32cb1a34eaf2d337bbf7ec018df90c9b2ff80466) - **docs:** improve doctests for ndarray instances in `ndarray/concat1d` [(#9344)](https://github.com/stdlib-js/stdlib/pull/9344) _(by Lokesh Ranjan)_
677-
- [`fdd3aa1`](https://github.com/stdlib-js/stdlib/commit/fdd3aa1bd398edec9c30a05569b05a3aba1897ec) - **docs:** update `ndarray` TypeScript declarations [(#9335)](https://github.com/stdlib-js/stdlib/pull/9335) _(by stdlib-bot)_
680+
- [`fdd3aa1`](https://github.com/stdlib-js/stdlib/commit/fdd3aa1bd398edec9c30a05569b05a3aba1897ec) - **feat:** update `ndarray` TypeScript declarations [(#9335)](https://github.com/stdlib-js/stdlib/pull/9335) _(by stdlib-bot)_
678681
- [`46d9a44`](https://github.com/stdlib-js/stdlib/commit/46d9a441ddf70ca13ac2a8d61cf54c628876e537) - **docs:** improve doctests for ndarray instances in `ndarray/count-falsy` _(by Athan Reines)_
679682
- [`50ec01b`](https://github.com/stdlib-js/stdlib/commit/50ec01b7e6b99e92e033199246bae378a10ee479) - **style:** fix missing space _(by Athan Reines)_
680683
- [`a799baf`](https://github.com/stdlib-js/stdlib/commit/a799bafe59b868a07c99266ca494074a8037ce67) - **docs:** update examples _(by Athan Reines)_

some/README.md

Lines changed: 5 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,7 @@ var x = array( [ [ [ 1.0, 0.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 0.0, 6.0 ] ] ] );
4949

5050
// Perform reduction:
5151
var out = some( x, 3 );
52-
// returns <ndarray>
53-
54-
var v= out.get();
55-
// returns true
52+
// returns <ndarray>[ true ]
5653
```
5754

5855
The function accepts the following arguments:
@@ -70,7 +67,6 @@ By default, the function performs a reduction over all elements in a provided [`
7067

7168
```javascript
7269
var array = require( '@stdlib/ndarray/array' );
73-
var ndarray2array = require( '@stdlib/ndarray/to-array' );
7470

7571
// Create an input ndarray:
7672
var x = array( [ [ [ 1.0, 0.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 0.0, 6.0 ] ] ] );
@@ -82,17 +78,13 @@ var opts = {
8278

8379
// Perform reduction:
8480
var out = some( x, 2, opts );
85-
// returns <ndarray>
86-
87-
var v = ndarray2array( out );
88-
// returns [ true, true ]
81+
// returns <ndarray>[ true, true ]
8982
```
9083

9184
By default, the function returns an [`ndarray`][@stdlib/ndarray/ctor] having a shape matching only the non-reduced dimensions of the input [`ndarray`][@stdlib/ndarray/ctor] (i.e., the reduced dimensions are dropped). To include the reduced dimensions as singleton dimensions in the output [`ndarray`][@stdlib/ndarray/ctor], set the `keepdims` option to `true`.
9285

9386
```javascript
9487
var array = require( '@stdlib/ndarray/array' );
95-
var ndarray2array = require( '@stdlib/ndarray/to-array' );
9688

9789
// Create an input ndarray:
9890
var x = array( [ [ [ 1.0, 0.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 0.0, 6.0 ] ] ] );
@@ -105,10 +97,7 @@ var opts = {
10597

10698
// Perform reduction:
10799
var out = some( x, 2, opts );
108-
// returns <ndarray>
109-
110-
var v = ndarray2array( out );
111-
// returns [ [ [ true, true ] ] ]
100+
// returns <ndarray>[ [ [ true, true ] ] ]
112101
```
113102

114103
#### some.assign( x, n, out\[, options] )
@@ -130,13 +119,10 @@ var y = empty( [], {
130119

131120
// Perform reduction:
132121
var out = some.assign( x, 3, y );
133-
// returns <ndarray>
122+
// returns <ndarray>[ true ]
134123

135124
var bool = ( out === y );
136125
// returns true
137-
138-
var v = y.get();
139-
// returns true
140126
```
141127

142128
The function accepts the following arguments:
@@ -155,7 +141,6 @@ By default, the function performs a reduction over all elements in a provided [`
155141
```javascript
156142
var array = require( '@stdlib/ndarray/array' );
157143
var empty = require( '@stdlib/ndarray/empty' );
158-
var ndarray2array = require( '@stdlib/ndarray/to-array' );
159144

160145
// Create an input ndarray:
161146
var x = array( [ [ [ 1.0, 0.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 0.0, 6.0 ] ] ] );
@@ -172,13 +157,10 @@ var opts = {
172157

173158
// Perform reduction:
174159
var out = some.assign( x, 2, y, opts );
175-
// returns <ndarray>
160+
// returns <ndarray>[ true, true ]
176161

177162
var bool = ( out === y );
178163
// returns true
179-
180-
var v = ndarray2array( out );
181-
// returns [ true, true ]
182164
```
183165

184166
</section>

some/docs/repl.txt

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,9 @@
3535
--------
3636
> var x = {{alias:@stdlib/ndarray/array}}( [ [ 1, 0 ], [ 3, 4 ] ] );
3737
> var y = {{alias}}( x, 3 )
38-
<ndarray>
39-
> y.get()
40-
true
38+
<ndarray>[ true ]
4139
> y = {{alias}}( x, 3, { 'keepdims': true } )
42-
<ndarray>
43-
> {{alias:@stdlib/ndarray/to-array}}( y )
44-
[ [ true ] ]
45-
> y.get( 0, 0 )
46-
true
40+
<ndarray>[ [ true ] ]
4741

4842

4943
{{alias}}.assign( x, n, y[, options] )
@@ -82,11 +76,9 @@
8276
> var x = {{alias:@stdlib/ndarray/array}}( [ [ 1, 0 ], [ 3, 4 ] ] );
8377
> var y = {{alias:@stdlib/ndarray/from-scalar}}( false );
8478
> var out = {{alias}}.assign( x, 3, y )
85-
<ndarray>
79+
<ndarray>[ true ]
8680
> var bool = ( out === y )
8781
true
88-
> y.get()
89-
true
9082

9183
See Also
9284
--------

some/docs/types/index.d.ts

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,7 @@ interface Some {
8181
*
8282
* // Perform reduction:
8383
* var out = some( x, 3 );
84-
* // returns <ndarray>
85-
*
86-
* var v = out.get();
87-
* // returns true
84+
* // returns <ndarray>[ true ]
8885
*/
8986
<T = unknown>( x: InputArray<T>, n: integerndarray | number, options?: Options ): boolndarray;
9087

@@ -124,10 +121,7 @@ interface Some {
124121
*
125122
* // Perform reduction:
126123
* var out = some.assign( x, 3, y );
127-
* // returns <ndarray>
128-
*
129-
* var v = out.get();
130-
* // returns true
124+
* // returns <ndarray>[ true ]
131125
*/
132126
assign<T extends ndarray>( x: InputArray<unknown>, n: integerndarray | number, y: T, options?: BaseOptions ): T;
133127
}
@@ -161,10 +155,7 @@ interface Some {
161155
*
162156
* // Perform reduction:
163157
* var out = some( x, 3 );
164-
* // returns <ndarray>
165-
*
166-
* var v = out.get();
167-
* // returns true
158+
* // returns <ndarray>[ true ]
168159
*
169160
* @example
170161
* var Float64Array = require( '@stdlib/array/float64' );
@@ -193,10 +184,7 @@ interface Some {
193184
*
194185
* // Perform reduction:
195186
* var out = some.assign( x, 3, y );
196-
* // returns <ndarray>
197-
*
198-
* var v = out.get();
199-
* // returns true
187+
* // returns <ndarray>[ true ]
200188
*/
201189
declare var some: Some;
202190

some/lib/assign.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,7 @@ var DEFAULT_DTYPE = defaults.get( 'dtypes.integer_index' );
8888
*
8989
* // Perform reduction:
9090
* var out = assign( x, 6, y );
91-
* // returns <ndarray>
92-
*
93-
* var v = out.get();
94-
* // returns true
91+
* // returns <ndarray>[ true ]
9592
*/
9693
function assign( x, n, y, options ) {
9794
var opts;

some/lib/index.js

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,7 @@
4545
*
4646
* // Perform reduction:
4747
* var out = some( x, 6 );
48-
* // returns <ndarray>
49-
*
50-
* var v = out.get();
51-
* // returns true
48+
* // returns <ndarray>[ true ]
5249
*
5350
* @example
5451
* var Float64Array = require( '@stdlib/array/float64' );
@@ -78,10 +75,7 @@
7875
*
7976
* // Perform reduction:
8077
* var out = some.assign( x, 6, y );
81-
* // returns <ndarray>
82-
*
83-
* var v = out.get();
84-
* // returns true
78+
* // returns <ndarray>[ true ]
8579
*/
8680

8781
// MODULES //

some/lib/main.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,7 @@ var DEFAULT_DTYPE = defaults.get( 'dtypes.integer_index' );
9191
*
9292
* // Perform reduction:
9393
* var out = some( x, 3 );
94-
* // returns <ndarray>
95-
*
96-
* var v = out.get();
97-
* // returns true
94+
* // returns <ndarray>[ true ]
9895
*/
9996
function some( x, n, options ) {
10097
var opts;

0 commit comments

Comments
 (0)