Dear all,
I think I must be going crazy.... If I do
mean(rpois(1000000, 14))
I get:
[1] 13.50420
and again:
mean(rpois(1000000, 14))
[1] 13.49896
mean(rpois(1000000, 14))
[1] 13.50161
mean(rpois(1000000, 15))
[1] 14.49250
mean(rpois(1000000, 15))
[1] 14.49897
mean(rpois(1000000, 14.5))
[1] 13.99689
mean(rpois(1000000, 14.5))
[1] 13.9963
This was on a
platform alphaev6-dec-osf4.0e
major 1
minor 1.1
checking out on a
platform sparc-sun-solaris2.7
major 1
minor 1.0
I get the same
mean(rpois(100000, 14.5))
[1] 14.00347
mean(rpois(100000, 14.5))
[1] 14.00667
mean(rpois(100000, 14.5))
[1] 14.00675
It's fishy, isn't it...? I have generated lots of numbers, but I haven't
seen anything like this before....
I have also done
sapply(1:15, function(n) mean(rpois(1000000, n)))
[1] 1.000052 1.999150 2.996975 4.003843 4.996136 5.999065 6.999725
[8] 7.998869 9.003127 9.518397 10.512347 11.500405 12.510494 13.499788
[15] 14.504661
So, something happens at 10... And again:
sapply(1:15, function(n) mean(rpois(1000000, n)))
[1] 1.000173 2.001639 2.997016 4.000163 5.000802 5.992751 6.999794
[8] 7.997315 8.998479 9.517824 10.508328 11.507336 12.501885 13.502146
[15] 14.496810
Starting with --vanilla gives pretty much the same result...
trying different RNGs:
[1] 0.999031 2.000444 3.002296 3.997795 4.998880 5.995267 7.001894
[8] 7.999983 9.000267 9.513537 10.507142 11.502634 12.498944 13.498615
[15] 14.502410
After printing rpois (to see that I haven't replaced it with something
strange) and version, I call
Kjetil Kjernsmo
Graduate astronomy-student Problems worthy of attack
University of Oslo, Norway Prove their worth by hitting back
E-mail: kjetikj at astro.uio.no - Piet Hein
Homepage <URL:http://www.astro.uio.no/~kjetikj/>
Webmaster at skepsis.no
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help 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-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._