ILNumerics Ultimate VS

ExtensionMethodsitemT1 Method (BaseArrayT1, Int64)

ILNumerics Ultimate VS Documentation
ILNumerics - Technical Application Development
[numpy API] Returns a single element from this array according to the provided dimension index.

[ILNumerics numpy Module]

Namespace:  ILNumerics
Assembly:  ILNumerics.numpy (in ILNumerics.numpy.dll) Version: 5.4.0.0 (5.4.7431.3055)
Syntax

public static T1 item<T1>(
	this BaseArray<T1> A,
	long d0
)

Parameters

A
Type: ILNumericsBaseArrayT1
The ILNumerics n-dim array.
d0
Type: SystemInt64
Sequential index of the element to retrieve, as if the elements were stored in row-major order. -A.S.NumberOfElements <=d0<A.S.NumberOfElements.

Type Parameters

T1
Element type.

Return Value

Type: T1
Copy of the element as located by the index argument d0.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type BaseArrayT1. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Exceptions

ExceptionCondition
IndexOutOfRangeException if d0 exceeds the number of elements in the array.
Remarks

An index for dimension i can be negative and must evaluate to an element position in the range 0...A.S[i]-1.

This function does support the merging of trailing, unspecified dimensions as known from [!:ILNumerics.ExtensionMethods.GetValue(BaseArray<bool>, long, long, long, long, long, long, long)]. However, the element position is computed by assuming the elements to be laid-out sequentially in memory in row-major order. This function handles arbitrary storage orders, though, using its strides to compute the actual element position in memory.

[ILNumerics numpy Module]

See Also

Reference

[!:ILNumerics.ExtensionMethods.GetValue(BaseArray<bool>, long, long, long, long, long, long, long)]