on 12/03/2008 06:10 PM Bastian Offermann wrote:
> Hello,
> 
> can anybody help me out saving random numbers? What I am doing is to
> generate a series of random numbers and keep it as a zoo object.
> 
> z <- 1000
> 
> rn1 <- as.zoo(rnorm(z))
> 
> The random numbers will be analyzed and described in a LaTeX document,
> so I have to keep them static somehow. The fact that they are kept
> as a zoo object should not be of too much concern here. Thanks in advance.
> 
> Regards
> 
> Bastian Offermann

See ?set.seed, which will allow you to specify the seed for the RNG, so
that you can reproduce the same sequence again in the future:

  set.seed(1)
  rn1 <- as.zoo(rnorm(1000))

HTH,

Marc Schwartz


______________________________________________
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