My problem lies in the last line. I want to generate a set of numbers within the range corresponding to 1:10 from the random array of R.
R = rand(length(U),1);[B,I] = sort(R);R1 = totalarray(I,:);P1 = sort(R1(:,10));
arrayrandomrange
R = rand(length(U),1);[B,I] = sort(R);R1 = totalarray(I,:);P1 = sort(R1(:,10));
Best Answer