generating random tuples in python

Tim Roberts timr at probo.com
Tue Apr 21 07:23:30 CEST 2009


per <perfreem at gmail.com> wrote:
>
>i am generating a list of random tuples of numbers between 0 and 1
>using the rand() function, as follows:
>...
>how can i maximize the amount of "numeric distance" between the
>elements of this list, but still make sure that all the tuples 
>have numbers strictly between 0 and 1 (inclusive)?

In doing so, you will be making the numbers non-random.  Statistically
speaking, a sufficiently long series of random numbers will often have
short sequences that are very close to each other.
-- 
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.



More information about the Python-list mailing list