[Y,index] =
Shuffle(X)
Randomly sorts X.
If X is a vector, sorts all of X, so Y = X(index).
If X is an m-by-n matrix, sorts each column of X, so
for j=1:n, Y(:,j)=X(index(:,j),j).
Also see SORT,
Sample,
Randi, and
RandSample.
Psychtoolbox/PsychProbability/Shuffle.m