{smcl}
{* 18dec2003}{...}
{hline}
help for {hi:matcsort}
{hline}

{title:Sort columns of matrix}

{p 8 17 2}
{cmd:matcsort} {it:input_matrix} {it:output_matrix} [{cmd:,} {cmdab:dec:rease}]


{title:Description}

{p 4 4 2}
{cmd:matcsort} sorts each column of {it:input_matrix} into numeric order
and puts the resulting matrix into {it:output_matrix}. 
{it:input_matrix} and {it:output_matrix} may have the same name. 
The row names of {it:output_matrix} will be {cmd:r1} up, regardless
of input. 


{title:Options}

{p 4 8 2}
{cmd:decrease} specifies that values in each column should be in 
decreasing order. The default is increasing order. 


{title:Examples}

{p 4 8 2}{cmd:. matcsort A B}


{title:Author}

{p 4 4 2}
Nicholas J. Cox, University of Durham, U.K.{break}
n.j.cox@durham.ac.uk


{title:Acknowledgement}

{p 4 4 2}
Walter Forrest suggested the corresponding problem with rows. 


{title:Also see}

{p 4 13 2}
Online:  help for {help matrix}
