Iterators
Multidimensional array iterators.
Usage
var ns = require( '@stdlib/ndarray/iter' );
ns
Namespace containing utilities for iterating over multidimensional arrays.
var o = ns;
// returns {...}
nditerColumnEntries( x[, options] )
: create an iterator which returns[index, column]
pairs for each column in a matrix (or stack of matrices).nditerColumns( x[, options] )
: create an iterator which iterates over each column in a matrix (or stack of matrices).nditerEntries( x[, options] )
: create an iterator which returns[index, value]
pairs for each element in a providedndarray
.nditerIndices( shape[, options] )
: create an iterator which returns indices for use indexing into anndarray
having a specified shape.nditerInterleaveSubarrays( arr, ndims )
: create an iterator which iterates over interleaved subarrays.nditerMatrices( x[, options] )
: create an iterator which iterates over each matrix in a stack of matrices.nditerMatrixEntries( x[, options] )
: create an iterator which returns[index, matrix]
pairs for each matrix in a stack of matrices.nditerRowEntries( x[, options] )
: create an iterator which returns[index, row]
pairs for each row in a matrix (or stack of matrices).nditerRows( x[, options] )
: create an iterator which iterates over each row in a matrix (or stack of matrices).nditerSelectDimension( x, dim[, options] )
: create an iterator which iterates over each view along a specified dimension.nditerStacks( x, dims[, options] )
: create an iterator which iterates over each subarray in a stack of subarrays according to a list of specified stack dimensions.nditerSubarrays( x, ndims[, options] )
: create an iterator which iterates over each subarray in a stack of subarrays.nditer2arrayEach( iterator )
: create an iterator which converts each iteratedndarray
to a generic array.nditerValues( x[, options] )
: create an iterator which returns individual elements from a providedndarray
.
Examples
var objectKeys = require( '@stdlib/utils/keys' );
var ns = require( '@stdlib/ndarray/iter' );
console.log( objectKeys( ns ) );