ILNumerics Ultimate VS

ConcreteArrayT1, LocalT, InT, OutT, RetT, StorageTSubarray Method (BaseArray, BaseArray, BaseArray, BaseArray, BaseArray)

ILNumerics Ultimate VS Documentation
ILNumerics - Technical Application Development
Extract part of this array. Matlab® and numpy indexing.

[ILNumerics Core Module]

Namespace:  ILNumerics.Core.Arrays
Assembly:  ILNumerics.Core (in ILNumerics.Core.dll) Version: (5.5.7503.3146)

public RetT Subarray(
	BaseArray d0,
	BaseArray d1,
	BaseArray d2,
	BaseArray d3,
	BaseArray d4


Type: ILNumericsBaseArray
Range specification for dimension #0.
Type: ILNumericsBaseArray
Range specification for dimension #1.
Type: ILNumericsBaseArray
Range specification for dimension #2.
Type: ILNumericsBaseArray
Range specification for dimension #3.
Type: ILNumericsBaseArray
Range specification for dimension #4.

Return Value

Type: RetT
New array with parts of this array as specified by d0...d4.

IndexOutOfRangeException if the range provided in a specifier d0,... addresses a non existing element.
NotSupportedException if any of d0,... attempts to use an indexing feature which is not supported in the current ArrayStyle mode. For example, if d0 was provided as newaxis while being in ILNumericsV4 mode.

This method considers the given dimensional range specifiers to extract a subarray from this array. Both indexing styles: numpy and Matlab® indexing (ILNumericsV4) are supported. For such indexing features specific to one or the other style the current setting of ArrayStyle is considered. For example, in ILNumericsV4 array style (default) the last given dimension specifier may refer to elements inside merged, trailing, unspecified dimensions of this array (and not only inside this dimension) in the same manner as the 'linear indexing' feature known from Matlab®, Octave, ILNumerics version 4 et al.

For simple dimension specifiers d0,... the subarray creation is often optimized to be fast and efficient, often without requiring new memory for copying elements. Note, that the array returned may use the same element storage as this array in this case. Only when trying to modify either one of this array or the subarray a copy will be made. More complex subarray specifications may require iterating and copying addressed elements into new memory.

The setting MinNumberOfArrayDimensions (as controlled by ArrayStyle) is respected for the array returned.

[ILNumerics Core Module]

See Also


Other Resources