Sorts the rows of a matrix by the values in a specified column.
Namespace:
CenterSpace.NMath.CoreAssembly: NMath (in NMath.dll) Version: 5.1.0.0
Syntax
| C# |
|---|
public static FloatMatrix SortByColumn( FloatMatrix A, int col ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function SortByColumn ( _ A As FloatMatrix, _ col As Integer _ ) As FloatMatrix |
| Visual C++ |
|---|
public: static FloatMatrix^ SortByColumn( FloatMatrix^ A, int col ) |
Parameters
- A
- Type: CenterSpace.NMath.Core..::.FloatMatrix
On input, the matrix to be sorted. On output, the sorted matrix.
- col
- Type: System..::.Int32
Rows of the matrix will be sorted according to the values in this column of the matrix.
Return Value
A copy of the matrix A with rows sorted by according to the values in the column specifed by the column index col.
Remarks
During sorting NaN values are considered larger than everything
else so that all rows that contain a NaN value in the column specified by col
will appear at the bottom of the matrix.