Data from Fisher's paper: Confidence Limits for a Cross-Product Ratio.> ycol1 col2 [1,] 10 3 [2,] 2 15 fisher.test(y) Fisher's Exact Test for Count Data data: y p-value = 0.0005367 alternative hypothesis: true odds ratio is not equal to 1 95 percent confidence interval: 2.753438 300.682787 sample estimates: odds ratio 21.30533 The crude odds ratio in Fisher's paper is 25 and the lower 95%CI is 2.750. How come this is different here? Why is the estimate 21.30533 and how is the confidence limits calculated (is there a reference for a statistical paper other than that of Fisher)? -- View this message in context: http://www.nabble.com/Confidence-Limits-for-a-Cross-Product-Ratio-tp24320301p24320301.html Sent from the R help mailing list archive at Nabble.com.
The reason I had asked how and what method was used to calculated the confidence intervals of the odds ratio in the fisher.test is because I don't think it's the exact method based on permutations. It seems that the exact method is not implemented in R or anywhere else: "In a tactic originally suggested by Fisher, Cornfield developed an exact method for getting an odds ratio?s confidence interval. The calculations are complex and computer-intensive because iterative numerical solutions are required for quartic equations. Because of the calculational complexity, Cornfield?s method is seldom used. If you do a lot of this work, however, you might want to get and use the appropriate computer program. [The Cornfield method is not available in standard SAS, BMDP, or other packages, but can be found in the EPIINFOVersion 5 available from the Centers for Disease Control.]". Is the above correct? -- View this message in context: http://www.nabble.com/Confidence-Limits-for-a-Cross-Product-Ratio-tp24320301p24332314.html Sent from the R help mailing list archive at Nabble.com.
francogrex wrote:> Data from Fisher's paper: Confidence Limits for a Cross-Product Ratio. > >> y > col1 col2 > [1,] 10 3 > [2,] 2 15 > > fisher.test(y) > > Fisher's Exact Test for Count Data > > data: y > p-value = 0.0005367 > alternative hypothesis: true odds ratio is not equal to 1 > 95 percent confidence interval: > 2.753438 300.682787 > sample estimates: > odds ratio > 21.30533 > > The crude odds ratio in Fisher's paper is 25 and the lower 95%CI is 2.750. > How come this is different here? Why is the estimate 21.30533 and how is the > confidence limits calculated (is there a reference for a statistical paper > other than that of Fisher)? >(R is open source, you know. You _can_ read the code of fisher.test for yourself.) The estimated OR is the conditional MLE in the noncentral hypergeometric distribution. This is not equal to the crude OR, a fact that can be easily noted by the results being different(!), but it's also mentioned in places like Breslow/Day's book on case-control studies. The CI given is the intersection of the two exact one-sided 0.975 levels. (Exact in the sense that it looks for the parameter for which the p-value is exactly 0.025). Exact 2-sided intervals are awkward to do (insofar as they can even be defined) because of probability mass switching between the tails of the distribution. -- O__ ---- Peter Dalgaard ?ster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907