On Mon, 2003-11-10 at 11:28, Rajarshi Guha wrote:
> Hi,
>   I'me trying to write  a function that will shuffle a vector. At the
> moment I'm baically making a vector of randomized indices and then
> making  a new vector from the original one using these random indices.
> 
> However, is there an alternative (more elegant) method to do this? I
> tried help.search('shuffle') but it does'nt return anything relevant.

Seems I sent of the mail prematurely :-/
sample() allows me to get the randomzied indices

-------------------------------------------------------------------
Rajarshi Guha <[EMAIL PROTECTED]> <http://jijo.cjb.net>
GPG Fingerprint: 0CCA 8EE2 2EEB 25E2 AB04 06F7 1BB9 E634 9B87 56EE
-------------------------------------------------------------------
A mathematician is a device for turning coffee into theorems.
-- P. Erdos

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to