gtm_sort

Sorts the columns of argument matrix R in increasing order.

Synopsis

srtdR = gtm_sort(R)

Arguments

R - an (unsorted) matrix

Return

srtdR - the corresponding sorted matrix

Notes

The m-file implementation is simply an alias for MATLAB's built-in sort function. However, if a corresponding mex-file exists, this will be used instead; experience has shown that a C-implementation of (e.g.) quicksort works much faster.


The GTM Toolbox: Contents