Suppose I have a 100 x 100 matrix composed of some combination of 250s, 125s, 15s and 9s. I would like to return a sorted vector of all of the unique values in this matrix.
Something in the matter of:
sort(somefunction(matrix))=vector
The result I would like to get is thus:
vector=9,15,125,250
Is there a quick and easy way to do this?