Skip to content

Commit 72071b6

Browse files
committed
Auto-generated commit
1 parent 2249221 commit 72071b6

3 files changed

Lines changed: 31 additions & 6 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -918,6 +918,7 @@ A total of 49 issues were closed in this release:
918918

919919
<details>
920920

921+
- [`738b2c7`](https://github.com/stdlib-js/stdlib/commit/738b2c717eb26b3e374351f754d578f2035aaf20) - **docs:** update namespace table of contents [(#11916)](https://github.com/stdlib-js/stdlib/pull/11916) _(by stdlib-bot)_
921922
- [`0edd0da`](https://github.com/stdlib-js/stdlib/commit/0edd0dafa26d1c286fcf60de7f42c7f6214e7d87) - **docs:** update ToC _(by Athan Reines)_
922923
- [`c625170`](https://github.com/stdlib-js/stdlib/commit/c6251708ba16c75c5e7d98d245dc86d7738ebfc1) - **feat:** add `first`, `diagonal`, `reverseDimensions`, and `toUnflattened` to namespace _(by Athan Reines)_
923924
- [`f1cdb3d`](https://github.com/stdlib-js/stdlib/commit/f1cdb3dc2daa032c75f77b1960375452913a2d3f) - **feat:** add `fillDiagonal` to namespace _(by Athan Reines)_

README.md

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ The namespace exports the following functions to manipulate multidimensional arr
113113
- <span class="signature">[`colcat( arrays )`][@stdlib/ndarray/colcat]</span><span class="delimiter">: </span><span class="description">concatenate a list of one-dimensional or two-dimensional ndarrays as columns.</span>
114114
- <span class="signature">[`concat( arrays[, options] )`][@stdlib/ndarray/concat]</span><span class="delimiter">: </span><span class="description">concatenate a list of ndarrays along a specified ndarray dimension.</span>
115115
- <span class="signature">[`concat1d( ...arrays )`][@stdlib/ndarray/concat1d]</span><span class="delimiter">: </span><span class="description">return a one-dimensional ndarray formed by concatenating provided input arguments.</span>
116+
- <span class="signature">[`diagonal( x[, options] )`][@stdlib/ndarray/diagonal]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of the diagonal of a matrix (or stack of matrices).</span>
116117
- <span class="signature">[`fillBy( x, fcn[, thisArg] )`][@stdlib/ndarray/fill-by]</span><span class="delimiter">: </span><span class="description">fill an input ndarray according to a callback function.</span>
117118
- <span class="signature">[`fillSlice( x, value, ...s[, options] )`][@stdlib/ndarray/fill-slice]</span><span class="delimiter">: </span><span class="description">fill an input `ndarray` view with a specified value.</span>
118119
- <span class="signature">[`fill( x, value )`][@stdlib/ndarray/fill]</span><span class="delimiter">: </span><span class="description">fill an input `ndarray` with a specified value.</span>
@@ -131,6 +132,7 @@ The namespace exports the following functions to manipulate multidimensional arr
131132
- <span class="signature">[`push( x, ...values )`][@stdlib/ndarray/push]</span><span class="delimiter">: </span><span class="description">return a one-dimensional ndarray formed by appending provided scalar values to a one-dimensional input ndarray.</span>
132133
- <span class="signature">[`removeSingletonDimensions( x )`][@stdlib/ndarray/remove-singleton-dimensions]</span><span class="delimiter">: </span><span class="description">return a read-only view of an input ndarray with singleton dimensions removed.</span>
133134
- <span class="signature">[`reverseDimension( x, dim )`][@stdlib/ndarray/reverse-dimension]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of an input `ndarray` in which the order of elements along a specified dimension is reversed.</span>
135+
- <span class="signature">[`reverseDimensions( x, dims )`][@stdlib/ndarray/reverse-dimensions]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of an input `ndarray` in which the order of elements along specified dimensions is reversed.</span>
134136
- <span class="signature">[`reverse( x )`][@stdlib/ndarray/reverse]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of an input `ndarray` in which the order of elements along each dimension is reversed.</span>
135137
- <span class="signature">[`rot180( x[, options] )`][@stdlib/ndarray/rot180]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of an input ndarray rotated `180` degrees in a specified plane.</span>
136138
- <span class="signature">[`rot90( x[, options] )`][@stdlib/ndarray/rot90]</span><span class="delimiter">: </span><span class="description">return a **read-only** view of an input ndarray rotated `90` degrees in a specified plane.</span>
@@ -154,6 +156,8 @@ The namespace exports the following functions to manipulate multidimensional arr
154156
- <span class="signature">[`toRot90( x[, options] )`][@stdlib/ndarray/to-rot90]</span><span class="delimiter">: </span><span class="description">return a new `ndarray` where an input `ndarray` is rotated `90` degrees in a specified plane.</span>
155157
- <span class="signature">[`toRotl90( x, k )`][@stdlib/ndarray/to-rotl90]</span><span class="delimiter">: </span><span class="description">return a new `ndarray` where a matrix (or a stack of matrices) is rotated 90 degrees counterclockwise.</span>
156158
- <span class="signature">[`toRotr90( x, k )`][@stdlib/ndarray/to-rotr90]</span><span class="delimiter">: </span><span class="description">return a new `ndarray` where a matrix (or a stack of matrices) is rotated 90 degrees clockwise.</span>
159+
- <span class="signature">[`toUnflattened( x, dim, sizes )`][@stdlib/ndarray/to-unflattened]</span><span class="delimiter">: </span><span class="description">return a new `ndarray` in which a specified dimension of an input `ndarray` is expanded over multiple dimensions.</span>
160+
- <span class="signature">[`unflatten( x, dim, sizes )`][@stdlib/ndarray/unflatten]</span><span class="delimiter">: </span><span class="description">return a read-only view of an input ndarray in which a specified dimension is expanded over multiple dimensions.</span>
157161
- <span class="signature">[`unshift( x, ...values )`][@stdlib/ndarray/unshift]</span><span class="delimiter">: </span><span class="description">return a one-dimensional ndarray formed by prepending provided scalar values to a one-dimensional input ndarray.</span>
158162
- <span class="signature">[`vconcat( arrays )`][@stdlib/ndarray/vconcat]</span><span class="delimiter">: </span><span class="description">concatenate a list of ndarrays along the second-to-last dimension.</span>
159163
- <span class="signature">[`ndarrayWith( x, indices, value )`][@stdlib/ndarray/with]</span><span class="delimiter">: </span><span class="description">return a new ndarray with the element at a specified index replaced by a provided value.</span>
@@ -224,9 +228,11 @@ The namespace exports the following functions to index multidimensional arrays:
224228
<div class="namespace-toc">
225229

226230
- <span class="signature">[`at( x[, ...indices] )`][@stdlib/ndarray/at]</span><span class="delimiter">: </span><span class="description">return an `ndarray` element.</span>
231+
- <span class="signature">[`first( x[, options] )`][@stdlib/ndarray/first]</span><span class="delimiter">: </span><span class="description">return a read-only view of the first element (or subarray) along one or more `ndarray` dimensions.</span>
227232
- <span class="signature">[`ind2sub( shape, idx[, options] )`][@stdlib/ndarray/ind2sub]</span><span class="delimiter">: </span><span class="description">convert a linear index to an array of subscripts.</span>
228233
- <span class="signature">[`indexModes()`][@stdlib/ndarray/index-modes]</span><span class="delimiter">: </span><span class="description">list of ndarray index modes.</span>
229234
- <span class="signature">[`ndindex( x[, options] )`][@stdlib/ndarray/index]</span><span class="delimiter">: </span><span class="description">ndarray index constructor.</span>
235+
- <span class="signature">[`last( x[, options] )`][@stdlib/ndarray/last]</span><span class="delimiter">: </span><span class="description">return a read-only view of the last element (or subarray) along one or more `ndarray` dimensions.</span>
230236
- <span class="signature">[`sub2ind( shape, ...subscripts[, options] )`][@stdlib/ndarray/sub2ind]</span><span class="delimiter">: </span><span class="description">convert subscripts to a linear index.</span>
231237

232238
</div>
@@ -241,6 +247,7 @@ The namespace exports the following functions to convert multidimensional arrays
241247

242248
<div class="namespace-toc">
243249

250+
- <span class="signature">[`ndarraylike2scalar( x )`][@stdlib/ndarray/ndarraylike2scalar]</span><span class="delimiter">: </span><span class="description">convert an ndarray-like object to a scalar value.</span>
244251
- <span class="signature">[`ndarray2array( x )`][@stdlib/ndarray/to-array]</span><span class="delimiter">: </span><span class="description">convert an ndarray to a generic array.</span>
245252
- <span class="signature">[`ndarray2json( x )`][@stdlib/ndarray/to-json]</span><span class="delimiter">: </span><span class="description">serialize an ndarray as a JSON object.</span>
246253
- <span class="signature">[`ndarray2localeString( x[, locales[, options]] )`][@stdlib/ndarray/to-locale-string]</span><span class="delimiter">: </span><span class="description">serialize an ndarray as a locale-aware string.</span>
@@ -301,9 +308,7 @@ The namespace contains the following multidimensional array utility functions:
301308
- <span class="signature">[`defaults()`][@stdlib/ndarray/defaults]</span><span class="delimiter">: </span><span class="description">default ndarray settings.</span>
302309
- <span class="signature">[`dispatch( fcns, types, data, nargs, nin, nout )`][@stdlib/ndarray/dispatch]</span><span class="delimiter">: </span><span class="description">create an ndarray function interface which performs multiple dispatch.</span>
303310
- <span class="signature">[`forEach( x, fcn[, thisArg] )`][@stdlib/ndarray/for-each]</span><span class="delimiter">: </span><span class="description">invoke a callback function once for each ndarray element.</span>
304-
- <span class="signature">[`ndarraylike2scalar( x )`][@stdlib/ndarray/ndarraylike2scalar]</span><span class="delimiter">: </span><span class="description">convert an ndarray-like object to a scalar value.</span>
305311
- <span class="signature">[`orders()`][@stdlib/ndarray/orders]</span><span class="delimiter">: </span><span class="description">list of ndarray orders.</span>
306-
- <span class="signature">[`unflatten( x, dim, sizes )`][@stdlib/ndarray/unflatten]</span><span class="delimiter">: </span><span class="description">return a read-only view of an input ndarray in which a specified dimension is expanded over multiple dimensions.</span>
307312

308313
</div>
309314

@@ -420,12 +425,8 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
420425

421426
[@stdlib/ndarray/for-each]: https://github.com/stdlib-js/ndarray/tree/main/for-each
422427

423-
[@stdlib/ndarray/ndarraylike2scalar]: https://github.com/stdlib-js/ndarray/tree/main/ndarraylike2scalar
424-
425428
[@stdlib/ndarray/orders]: https://github.com/stdlib-js/ndarray/tree/main/orders
426429

427-
[@stdlib/ndarray/unflatten]: https://github.com/stdlib-js/ndarray/tree/main/unflatten
428-
429430
[@stdlib/ndarray/base]: https://github.com/stdlib-js/ndarray/tree/main/base
430431

431432
[@stdlib/ndarray/iter]: https://github.com/stdlib-js/ndarray/tree/main/iter
@@ -454,6 +455,8 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
454455

455456
[@stdlib/ndarray/same-kind-casts]: https://github.com/stdlib-js/ndarray/tree/main/same-kind-casts
456457

458+
[@stdlib/ndarray/ndarraylike2scalar]: https://github.com/stdlib-js/ndarray/tree/main/ndarraylike2scalar
459+
457460
[@stdlib/ndarray/to-array]: https://github.com/stdlib-js/ndarray/tree/main/to-array
458461

459462
[@stdlib/ndarray/to-json]: https://github.com/stdlib-js/ndarray/tree/main/to-json
@@ -464,12 +467,16 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
464467

465468
[@stdlib/ndarray/at]: https://github.com/stdlib-js/ndarray/tree/main/at
466469

470+
[@stdlib/ndarray/first]: https://github.com/stdlib-js/ndarray/tree/main/first
471+
467472
[@stdlib/ndarray/ind2sub]: https://github.com/stdlib-js/ndarray/tree/main/ind2sub
468473

469474
[@stdlib/ndarray/index-modes]: https://github.com/stdlib-js/ndarray/tree/main/index-modes
470475

471476
[@stdlib/ndarray/index]: https://github.com/stdlib-js/ndarray/tree/main/index
472477

478+
[@stdlib/ndarray/last]: https://github.com/stdlib-js/ndarray/tree/main/last
479+
473480
[@stdlib/ndarray/sub2ind]: https://github.com/stdlib-js/ndarray/tree/main/sub2ind
474481

475482
[@stdlib/ndarray/data-buffer]: https://github.com/stdlib-js/ndarray/tree/main/data-buffer
@@ -540,6 +547,8 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
540547

541548
[@stdlib/ndarray/concat1d]: https://github.com/stdlib-js/ndarray/tree/main/concat1d
542549

550+
[@stdlib/ndarray/diagonal]: https://github.com/stdlib-js/ndarray/tree/main/diagonal
551+
543552
[@stdlib/ndarray/fill-by]: https://github.com/stdlib-js/ndarray/tree/main/fill-by
544553

545554
[@stdlib/ndarray/fill-slice]: https://github.com/stdlib-js/ndarray/tree/main/fill-slice
@@ -576,6 +585,8 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
576585

577586
[@stdlib/ndarray/reverse-dimension]: https://github.com/stdlib-js/ndarray/tree/main/reverse-dimension
578587

588+
[@stdlib/ndarray/reverse-dimensions]: https://github.com/stdlib-js/ndarray/tree/main/reverse-dimensions
589+
579590
[@stdlib/ndarray/reverse]: https://github.com/stdlib-js/ndarray/tree/main/reverse
580591

581592
[@stdlib/ndarray/rot180]: https://github.com/stdlib-js/ndarray/tree/main/rot180
@@ -622,6 +633,10 @@ Copyright &copy; 2016-2026. The Stdlib [Authors][stdlib-authors].
622633

623634
[@stdlib/ndarray/to-rotr90]: https://github.com/stdlib-js/ndarray/tree/main/to-rotr90
624635

636+
[@stdlib/ndarray/to-unflattened]: https://github.com/stdlib-js/ndarray/tree/main/to-unflattened
637+
638+
[@stdlib/ndarray/unflatten]: https://github.com/stdlib-js/ndarray/tree/main/unflatten
639+
625640
[@stdlib/ndarray/unshift]: https://github.com/stdlib-js/ndarray/tree/main/unshift
626641

627642
[@stdlib/ndarray/vconcat]: https://github.com/stdlib-js/ndarray/tree/main/vconcat

base/README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ var o = ns;
8181
- <span class="signature">[`countTruthy( arrays )`][@stdlib/ndarray/base/count-truthy]</span><span class="delimiter">: </span><span class="description">count the number of truthy elements in an ndarray.</span>
8282
- <span class="signature">[`ndarray( dtype, buffer, shape, strides, offset, order )`][@stdlib/ndarray/base/ctor]</span><span class="delimiter">: </span><span class="description">create a multidimensional array.</span>
8383
- <span class="signature">[`data( x )`][@stdlib/ndarray/base/data-buffer]</span><span class="delimiter">: </span><span class="description">return the underlying data buffer of a provided ndarray.</span>
84+
- <span class="signature">[`diagonal( x, dims, k, writable )`][@stdlib/ndarray/base/diagonal]</span><span class="delimiter">: </span><span class="description">return a view of the diagonal of a matrix (or stack of matrices).</span>
8485
- <span class="signature">[`dtypeAlignment( [dtype] )`][@stdlib/ndarray/base/dtype-alignment]</span><span class="delimiter">: </span><span class="description">return the alignment (in bytes) for an underlying array data type.</span>
8586
- <span class="signature">[`dtypeChar( [dtype] )`][@stdlib/ndarray/base/dtype-char]</span><span class="delimiter">: </span><span class="description">return the single letter abbreviation for an underlying array data type.</span>
8687
- <span class="signature">[`dtypeChars( [kind] )`][@stdlib/ndarray/base/dtype-chars]</span><span class="delimiter">: </span><span class="description">list of ndarray data type single letter character abbreviations.</span>
@@ -104,6 +105,7 @@ var o = ns;
104105
- <span class="signature">[`expandDimensions( x, dim, writable )`][@stdlib/ndarray/base/expand-dimensions]</span><span class="delimiter">: </span><span class="description">expand the shape of an array by inserting a new dimension of size one at a specified dimension index.</span>
105106
- <span class="signature">[`falses( dtype, shape, order )`][@stdlib/ndarray/base/falses]</span><span class="delimiter">: </span><span class="description">create an ndarray filled with `false` values and having a specified shape and data type.</span>
106107
- <span class="signature">[`fillBy( x, fcn[, thisArg] )`][@stdlib/ndarray/base/fill-by]</span><span class="delimiter">: </span><span class="description">fill an input ndarray according to a callback function.</span>
108+
- <span class="signature">[`fillDiagonal( x, value, dims, k )`][@stdlib/ndarray/base/fill-diagonal]</span><span class="delimiter">: </span><span class="description">fill a specified diagonal of a matrix (or stack of matrices) with a scalar value.</span>
107109
- <span class="signature">[`fill( x, value )`][@stdlib/ndarray/base/fill]</span><span class="delimiter">: </span><span class="description">fill an input ndarray with a specified value.</span>
108110
- <span class="signature">[`find( arrays, predicate[, thisArg] )`][@stdlib/ndarray/base/find]</span><span class="delimiter">: </span><span class="description">return the first element in an ndarray which passes a test implemented by a predicate function.</span>
109111
- <span class="signature">[`flag( x, name )`][@stdlib/ndarray/base/flag]</span><span class="delimiter">: </span><span class="description">return a specified flag for a provided ndarray.</span>
@@ -173,6 +175,7 @@ var o = ns;
173175
- <span class="signature">[`reinterpretComplex64( x )`][@stdlib/ndarray/base/reinterpret-complex64]</span><span class="delimiter">: </span><span class="description">reinterpret a single-precision complex floating-point ndarray as a real-valued single-precision floating-point ndarray containing interleaved real and imaginary components.</span>
174176
- <span class="signature">[`removeSingletonDimensions( x, writable )`][@stdlib/ndarray/base/remove-singleton-dimensions]</span><span class="delimiter">: </span><span class="description">remove singleton dimensions.</span>
175177
- <span class="signature">[`reverseDimension( x, dim, writable )`][@stdlib/ndarray/base/reverse-dimension]</span><span class="delimiter">: </span><span class="description">return a view of an input ndarray in which the order of elements along a specified dimension is reversed.</span>
178+
- <span class="signature">[`reverseDimensions( x, dims, writable )`][@stdlib/ndarray/base/reverse-dimensions]</span><span class="delimiter">: </span><span class="description">return a view of an input ndarray in which the order of elements along specified dimensions is reversed.</span>
176179
- <span class="signature">[`reverse( x, writable )`][@stdlib/ndarray/base/reverse]</span><span class="delimiter">: </span><span class="description">return a view of an input ndarray in which the order of elements along each dimension is reversed.</span>
177180
- <span class="signature">[`rot180( x, dims, writable )`][@stdlib/ndarray/base/rot180]</span><span class="delimiter">: </span><span class="description">rotate an ndarray 180 degrees in a specified plane.</span>
178181
- <span class="signature">[`rot90( x, dims, k, writable )`][@stdlib/ndarray/base/rot90]</span><span class="delimiter">: </span><span class="description">rotate an ndarray 90 degrees in a specified plane.</span>
@@ -378,6 +381,8 @@ console.log( objectKeys( ns ) );
378381

379382
[@stdlib/ndarray/base/data-buffer]: https://github.com/stdlib-js/ndarray/tree/main/base/data-buffer
380383

384+
[@stdlib/ndarray/base/diagonal]: https://github.com/stdlib-js/ndarray/tree/main/base/diagonal
385+
381386
[@stdlib/ndarray/base/dtype-alignment]: https://github.com/stdlib-js/ndarray/tree/main/base/dtype-alignment
382387

383388
[@stdlib/ndarray/base/dtype-char]: https://github.com/stdlib-js/ndarray/tree/main/base/dtype-char
@@ -424,6 +429,8 @@ console.log( objectKeys( ns ) );
424429

425430
[@stdlib/ndarray/base/fill-by]: https://github.com/stdlib-js/ndarray/tree/main/base/fill-by
426431

432+
[@stdlib/ndarray/base/fill-diagonal]: https://github.com/stdlib-js/ndarray/tree/main/base/fill-diagonal
433+
427434
[@stdlib/ndarray/base/fill]: https://github.com/stdlib-js/ndarray/tree/main/base/fill
428435

429436
[@stdlib/ndarray/base/find]: https://github.com/stdlib-js/ndarray/tree/main/base/find
@@ -562,6 +569,8 @@ console.log( objectKeys( ns ) );
562569

563570
[@stdlib/ndarray/base/reverse-dimension]: https://github.com/stdlib-js/ndarray/tree/main/base/reverse-dimension
564571

572+
[@stdlib/ndarray/base/reverse-dimensions]: https://github.com/stdlib-js/ndarray/tree/main/base/reverse-dimensions
573+
565574
[@stdlib/ndarray/base/reverse]: https://github.com/stdlib-js/ndarray/tree/main/base/reverse
566575

567576
[@stdlib/ndarray/base/rot180]: https://github.com/stdlib-js/ndarray/tree/main/base/rot180

0 commit comments

Comments
 (0)