Revised: 05/24/2011 -- Bug Fix: Now calculates confidence intervals
using Yates continuity correction, so as to be consistent with Fleiss's
algorithm. Also added lower and upper limiting 2x2 tables, so users can
calculate lower and upper CIs for parameters not appearing in my
This page computes various statistics from a 2-by-2 table. It will calculate the Yates-corrected chi-square, the Mantel-Haenszel chi-square, the Fisher Exact Test, and other indices relevant to various special kinds of 2-by-2 tables:
Many of these concepts are explained in detail in an online Evidence-based Medicine Glossary. For more information about a particular index, click on the <more info> link for that index.
Confidence intervals for the estimated parameters are computed by a general method (based on "constant chi-square boundaries") given in: Statistical Methods for Rates and Proportions (2nd Ed.) Section 5.6, by Joseph L. Fleiss (Pub: John Wiley & Sons, New York, 1981). This method is also described in Numerical Recipes in C (2nd Ed.) Section 15.6, by William H. Press et al. (Pub: Cambridge University Press, Cambridge UK, 1992)
Enter numbers into the four cells below. Make sure that the row and column totals add up correctly. Then click the Compute button.
Warning: Do not enter cell counts with a leading zero! That is, if a cell count is 34, enter it as 34, not as 034. Some browsers will mis-interpret some numbers entered with leading zeros, and will produce wrong results (with no warning message). For more information about this, and for other things to be aware of before using this page for the first time, make sure you read the JavaStat user interface guidelines.
Observed Contingency Table