[R] runif and sample with reproducibility

Dirk Eddelbuettel edd at debian.org
Mon Jan 5 20:04:15 CET 2004


On Mon, Jan 05, 2004 at 01:07:08PM +0100, Eric ESPOSITO wrote:
> I would like to sample a population but the result needs to be
> reproducible, using 'runif' or 'sample' is the good way to do it but I
> can't manage to make the results reproducible even with the 'set.seed'
> function.
> My aim is that th call to 'sample(1:100,10)' gives always the same result,
> how can I do that?

help(set.seed)

Hth, Dirk

-- 
The relationship between the computed price and reality is as yet unknown.  
                                             -- From the pac(8) manual page




More information about the R-help mailing list