[Rd] .Random.seed resetting (PR#656)

lej25@statslab.cam.ac.uk lej25@statslab.cam.ac.uk
Mon, 11 Sep 2000 13:13:29 +0200 (MET DST)


Full_Name: Lara Jamieson
Version: 1.1.1
OS: Linux
Submission from: (NULL) (131.111.20.203)


I've checked for other reports on this and can't find anything.  It seems that 
the .Random.seed isn't updated properly after using rm(.Random.seed).  Mu 
understanding from the help file indicates that a new 'random' seed will be
generated.
It appears that sometimes the old one is just reinstated.

I removed my .RData file and the problem remains.  It seems to happen when calls
are 
made in succession to the same 'random generation type' function; but appears to

work when different calls are made in succession.
An example is given below.  I was using the sample command when I found the
problem 
but it happens with runif as well...

> runif(1)
[1] 0.5551602
> runif(1)
[1] 0.2575637
> rm(.Random.seed)
> runif(1)
[1] 0.5551602
> rm(.Random.seed)
> rm(.Random.seed)
Warning message: 
remove: variable ".Random.seed" was not found 
> runif(1)
[1] 0.2575637

Thanks,
Lara

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._