Matrix.With Row Index<T, TKey> Method
Sets the row index of a matrix.
Definition
Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.1.3
C#
The matrix with the updated row index.
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.1.3
public static Matrix<T> WithRowIndex<T, TKey>(
this Matrix<T> matrix,
IList<TKey> index
)
Parameters
- matrix Matrix<T>
- The matrix whose row index is to be set.
- index IList<TKey>
- The index to set for the rows of the matrix.
Type Parameters
- T
- The type of the elements of the matrix.
- TKey
- The type of the keys of the index.
Return Value
Matrix<T>The matrix with the updated row index.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type Matrix<T>. 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
Argument | matrix is null. |
Dimension | The length of index does not equal the number of rows in matrix. |