[R] Yate´s correction for continuity for a 2 x 2 contingency table
Peter Ho
peter at fe.up.pt
Wed Nov 20 22:51:56 CET 2002
Dear list readers,
This question is concerned with the use of the chisq.test() in R.
A test was conducted to determine the difference between 2 samples A and
B. Column I consisted of correct and incorrect assessment of 30 matched
pairs (AA or BB) , whereas column II consisted of correct and incorrect
assessment of 30 unmatched pairs (AB or BA). This example is given in a
book on the sensory evaluation techniques. The author's did not use
Yate´s correction for continuity in their analysis of the data.
I am trying to decide whether Yate´s correction for continuity should be
used when analysing a 2x2 contigency table using the chi-square test. I
have found conflicting views in literature with some people for and
others against. The analysis with or without Yate´s correction gives
conflicting results.
> x <- matrix(c(17, 13, 9, 21), nc = 2)
> chisq.test(x,correct = TRUE)
Pearson's Chi-squared test with Yates' continuity correction
data: x
X-squared = 3.3258, df = 1, p-value = 0.0682
> chisq.test(x,correct = F)
Pearson's Chi-squared test
data: x
X-squared = 4.3439, df = 1, p-value = 0.03714
>
The same data analysed using Fisher's exact test is similar to the
chi-square with Yate´s correction
> fisher.test(x)
Fisher's Exact Test for Count Data
data: x
p-value = 0.06728
alternative hypothesis: true odds ratio is not equal to 1
95 percent confidence interval:
0.9354766 10.1716022
sample estimates:
odds ratio
2.992580
I suppose looking at the results, the correct conclusion should be taken
using the correction for continuity. In fact, the statistics books I
have read suggest the use of Yate´s correction for continuity. (for
example, Nonparametric statistics - Sidney Siegel and John Castellan 1988)
I would like to hear anyone's view on this, especially statisticians.
Thanks in advance
Peter
----------------------------------
ISR-Porto
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list