MATLAB: Min to Max in MatLab

minminmax

Which command do I need to order values from min to max?
Something like: v1 = [2, 5, 9, 1]
And the output should be: v1 = 1, 2, 5, 9

Best Answer

v1 = sort(v1)