Problems? Is your data what you think it is? | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
If I am correct, all solutions presented so far focus on getting one element. I've been looking for an efficient way to do exactly what spurperl is looking for, only for a number of samples. Ie., I want to say @indices = DrawSamplesUneven(@elements, 5); and get five indices. Any ideas? Update: See my previous question Drawing samples from a set (regarding drawing one sample) Update: Forgot to mention that of course I want to get five different indices. In reply to Re: Weighted random numbers generator
by crenz
|
|