Skip to content
Prev 85981 / 398502 Next

difference between rnorm(1000, 0, 1) and running rnorm(500, 0, 1) twice

On 2/8/2006 4:53 AM, Bj??rn-Helge Mevik wrote:
This isn't really something that can be proved by a test.  Perhaps the 
current implementation makes those equal only because 500 is even, or 
divisible by 5, or whatever...

I think the intention is that those should be equal, but in a quick 
search I've been unable to find a documented guarantee of that.  So I 
would take a defensive stance and assume that there may be conditions 
where c(rnorm(m), rnorm(n)) is not equal to rnorm(m+n).

If someone can point out the document I missed, I'd appreciate it.

Duncan Murdoch