>>>>> Ross Ihaka writes:
> A cut and paste typo has crept in and is rendering all values returned
> for the hypergeometric distribution incorrect. The problem is in
> src/main/arithmetic.c in the function "math4". The lines
> PROTECT(sy = allocVector(REALSXP, n));
> a = REAL(sa);
> b = REAL(sb);
> c = REAL(sc);
> d = REAL(sc); /* <-- change this line */
> y = REAL(sy);
> should read
> PROTECT(sy = allocVector(REALSXP, n));
> a = REAL(sa);
> b = REAL(sb);
> c = REAL(sc);
> d = REAL(sd); /* corrected */
> y = REAL(sy);
> This will be part of the official 2nd patch to 0.49, but I'm pointing
it
> out anyway.
Thanks for the patch.
It fixes the problem reported by myself on 25 Apr 1997 (makes my Fisher
test work again) and by Ennapadam Venkatraman <VENKAT@biosta.mskcc.org>
on 30 Apr 1997.
Note that the problem with `rhyper(5,200,250,60)' never returning still
seems to exist.
-k
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
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
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-