Skip to content

Commit 34a837f

Browse files
authored
feat: update ndarray/base TypeScript declarations
PR-URL: #9447 Reviewed-by: Athan Reines <kgryte@gmail.com>
1 parent 7899877 commit 34a837f

1 file changed

Lines changed: 4 additions & 21 deletions

File tree

  • lib/node_modules/@stdlib/ndarray/base/docs/types

lib/node_modules/@stdlib/ndarray/base/docs/types/index.d.ts

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -3158,34 +3158,17 @@ interface Namespace {
31583158
*
31593159
* @param x - input array
31603160
* @param n - number of singleton dimensions to prepend
3161+
* @param writable - boolean indicating whether a returned array should be writable
31613162
* @returns output array
31623163
*
31633164
* @example
31643165
* var array = require( '@stdlib/ndarray/array' );
31653166
*
31663167
* var x = array( [ [ 1, 2 ], [ 3, 4 ] ] );
3167-
* // returns <ndarray>
3168-
*
3169-
* var shx = x.shape;
3170-
* // returns [ 2, 2 ]
3171-
*
3172-
* var y = ns.prependSingletonDimensions( x, 3 );
3173-
* // returns <ndarray>
3174-
*
3175-
* var shy = y.shape;
3176-
* // returns [ 1, 1, 1, 2, 2 ]
3177-
*
3178-
* var v = y.get( 0, 0, 0, 0, 0 );
3179-
* // returns 1
3180-
*
3181-
* v = y.get( 0, 0, 0, 0, 1 );
3182-
* // returns 2
3183-
*
3184-
* v = y.get( 0, 0, 0, 1, 0 );
3185-
* // returns 3
3168+
* // returns <ndarray>[ [ 1, 2 ], [ 3, 4 ] ]
31863169
*
3187-
* v = y.get( 0, 0, 0, 1, 1 );
3188-
* // returns 4
3170+
* var y = ns.prependSingletonDimensions( x, 3, false );
3171+
* // returns <ndarray>[ [ [ [ [ 1, 2 ], [ 3, 4 ] ] ] ] ]
31893172
*/
31903173
prependSingletonDimensions: typeof prependSingletonDimensions;
31913174

0 commit comments

Comments
 (0)