sort2 does not work on a column vector
When the argument to sort2 is a column vector (i.e. the size is Nx1), the returned indices array is all-zeroes.
Passing the transposed version of the column to the function results in the correct indices.
When the argument to sort2 is a column vector (i.e. the size is Nx1), the returned indices array is all-zeroes.
Passing the transposed version of the column to the function results in the correct indices.