diff --git a/lib/node_modules/@stdlib/ndarray/includes/README.md b/lib/node_modules/@stdlib/ndarray/includes/README.md index 0d212cc04e65..60ab5e05aca1 100644 --- a/lib/node_modules/@stdlib/ndarray/includes/README.md +++ b/lib/node_modules/@stdlib/ndarray/includes/README.md @@ -70,7 +70,6 @@ By default, the function performs a reduction over all elements in a provided [` ```javascript var array = require( '@stdlib/ndarray/array' ); -var ndarray2array = require( '@stdlib/ndarray/to-array' ); // Create an input ndarray: var x = array( [ [ [ 1.0, 2.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 5.0, 6.0 ] ] ] ); @@ -80,17 +79,13 @@ var x = array( [ [ [ 1.0, 2.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 5.0, 6.0 ] ] ] ); var out = includes( x, 5.0, { 'dims': [ 1, 2 ] }); -// returns - -var v = ndarray2array( out ); -// returns [ false, false, true ] +// returns [ false, false, true ] ``` 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`. ```javascript var array = require( '@stdlib/ndarray/array' ); -var ndarray2array = require( '@stdlib/ndarray/to-array' ); // Create an input ndarray: var x = array( [ [ [ 1.0, 2.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 5.0, 6.0 ] ] ] ); @@ -101,10 +96,7 @@ var out = includes( x, 5.0, { 'dims': [ 1, 2 ], 'keepdims': true }); -// returns - -var v = ndarray2array( out ); -// returns [ [ [ false ] ], [ [ false ] ], [ [ true ] ] ] +// returns [ [ [ false ] ], [ [ false ] ], [ [ true ] ] ] ``` #### includes.assign( x, searchElement, out\[, options] ) @@ -151,7 +143,6 @@ By default, the function performs a reduction over all elements in a provided [` ```javascript var array = require( '@stdlib/ndarray/array' ); var empty = require( '@stdlib/ndarray/empty' ); -var ndarray2array = require( '@stdlib/ndarray/to-array' ); // Create an input ndarray: var x = array( [ [ [ 1.0, 2.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 5.0, 6.0 ] ] ] ); @@ -161,6 +152,7 @@ var x = array( [ [ [ 1.0, 2.0 ] ], [ [ 3.0, 4.0 ] ], [ [ 5.0, 6.0 ] ] ] ); var y = empty( [ 3 ], { 'dtype': 'bool' }); +// returns [ false, false, true ] // Perform reduction: var out = includes.assign( x, 5.0, y, { @@ -169,9 +161,6 @@ var out = includes.assign( x, 5.0, y, { var bool = ( out === y ); // returns true - -var v = ndarray2array( y ); -// returns [ false, false, true ] ``` diff --git a/lib/node_modules/@stdlib/ndarray/includes/docs/repl.txt b/lib/node_modules/@stdlib/ndarray/includes/docs/repl.txt index 04d9390e2f88..e9c3d78a06f1 100644 --- a/lib/node_modules/@stdlib/ndarray/includes/docs/repl.txt +++ b/lib/node_modules/@stdlib/ndarray/includes/docs/repl.txt @@ -39,9 +39,7 @@ > y.get() true > y = {{alias}}( x, 3.0, { 'keepdims': true } ) - - > {{alias:@stdlib/ndarray/to-array}}( y ) - [ [ true ] ] + [ [ true ] ] > y.get( 0, 0 ) true