To sort a vector in ascending order it would seem completely obvious to type
Who cares what the second argument is, when the first is a vector?
But matlab views [1,3,2] as a 1x3 vector, so that you have to set the second arguemnt to 2.
Since matlab can recognize a vector with
Is there any reason why the sort command doesn't simply ignore the second argument when the first is a vector? This would save many people hours of puzzlement I think.