Index<T>.Get Slice Method
Definition
Namespace: Numerics.NET.DataAnalysis
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
Overload List
Get | Returns a slice of the current index. |
Get | Returns a slice of the current sorted index. |
Get | Returns a slice of the current index. |
GetSlice(Slice)
Returns a slice of the current index.
public virtual Index<T> GetSlice(
Slice slice
)
Parameters
Return Value
Index<T>A new index of the same type.
Exceptions
Argument | One or more of the indexes in slice is less than zero or greater than or equal to the length of the index. |
GetSlice(T, T)
Returns a slice of the current sorted index.
public virtual Index<T> GetSlice(
T startKey,
T endKey
)
Parameters
- startKey T
- The first key to be included in the new index.
- endKey T
- The zero-based index of the last element in the new index.
Return Value
Index<T>A new index of the same type.
Exceptions
Key | startKey is not a key in the index. -or- endKey is not a key in the index. |
Invalid | The index is not sorted. |
GetSlice(Int32, Int32, Int32)
Returns a slice of the current index.
public virtual Index<T> GetSlice(
int startIndex,
int endIndex,
int stride
)
Parameters
- startIndex Int32
- The zero-based index of the first element in the new index.
- endIndex Int32
- The zero-based index of the last element in the new index.
- stride Int32
- The number of items between elements in the new index.
Return Value
Index<T>A new index of the same type.
Exceptions
Argument | startIndex is less than zero or greater than the length of the index. -or- endIndex is less than zero or greater than the length of the index. |