[SciPy-user] choose at random all elements in a array...
Sat Aug 4 05:05:17 CDT 2007
> Say I have an array with 250 000 values.
> I want to choose at random _all_ the elements of this array,
> _once and only once_.
> How can I do this ?
You can simply use a random permutation:
a = numpy.array([1, 2, 3, 4, 5, 6])
More information about the SciPy-user