On 12/10/06, Milton Cezar Ribeiro <milton_ruser at yahoo.com.br> wrote: > I have a binary matrix (dim 100x100) filled with values 0 and 1. I need select a record "n" positions of that matrix when values are 1. How can I do that? Do you mean extracting the indexes of n randomly chosen elements of the matrix which are equal to one? Paul