Feeling very stupid here.

I just want to randomly-ordered some integers, e.g. the numbers 1 to
100, with each element present once only in a random order. 
I suspect I need to randomly sample a population 1-100, remove that
number, then randomly sample what is left until they've all gone,  but I
can't seem to find the right combination of order/sort/sample + runif.

I fear it can't be that hard - has anyone cracked this?

Stuart

Dr Stuart J Leask DM MRCPsych MA BChir
Clinical Senior Lecturer and Honorary Consultant in Clinical Psychiatry
University Dept of Psychiatry, A Floor, Queen's Medical Centre,
Nottingham. NG7 2UH
www: Google "Dr Stuart Leask"
 

This message has been checked for viruses but the contents of an attachment
may still contain software viruses, which could damage your computer system:
you are advised to perform your own checks. Email communications with the
University of Nottingham may be monitored as permitted by UK legislation.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to