anja.von.heydebreck@merck.de
2004-Jul-07 17:19 UTC
[Rd] negative p-value from fisher.test() (PR#7064)
Full_Name: Anja von Heydebreck Version: 1.9.1 OS: Linux Submission from: (NULL) (155.250.128.25) I obtained a negative p-value from the fisher.test() function:> fisher.test(matrix(c(14576,3023,89,68),2), alternative="g")$p.value[1] -8.426593e-13 With R 1.8.1, I got a p-value of -6.239231e-12 for this example. Anja von Heydebreck
maechler@stat.math.ethz.ch
2004-Jul-07 17:52 UTC
[Rd] negative p-value from fisher.test() (PR#7064)
>>>>> "anja" == anja von heydebreck <anja.von.heydebreck@merck.de> >>>>> on Wed, 7 Jul 2004 17:19:01 +0200 (CEST) writes:anja> Full_Name: Anja von Heydebreck Version: 1.9.1 OS: anja> Linux Submission from: (NULL) (155.250.128.25) anja> I obtained a negative p-value from the fisher.test() anja> function: >> fisher.test(matrix(c(14576,3023,89,68),2), >> alternative="g")$p.value anja> [1] -8.426593e-13 [I do get a slightly different negative P-value here]. anja> With R 1.8.1, I got a p-value of -6.239231e-12 for anja> this example. (which is slightly worse ;-) anja> Anja von Heydebreck Thank you, Anja! Note that this is the 2x2 case which does not resort to the (in)famous FEXACT routine. The rounding / precision problem is rather from dhyper() and/or phyper(). Now, as bug report PR#6772 "phyper accuracy and efficiency", Morten Welinder had proposed a new algorithm for phyper(). I'm about to try that and see if it cures this example. Best regards, Martin Maechler