Continuity correction in proportion test Can you please clarify to me when to use continuity correction in proportion test please? I'm using this formula in R and I want to know the difference in the option correct= TRUE or FALSE. Also, I noticed the p value with correction goes up, so I'm just concerned if I'm using this option (TRUE or FALSE) correctly? how this might impacts my analysis. Any help is really appreciated!
prop.test(x=c(84,105.5),n=c(99,146),correct = TRUE)

Thank you

There are many opinions on how to best test for 2 x 2 contingency tables like this. Here the prop.test implements a chi-squared test. The issue is that in some cases data from a 2 x 2 contingency table isn't well approximated by the chi-squared distribution under the null. This can lead to p-values that are too small. Yates continuity correction adjusted for this but can lead to p-values that are too large.
There are other tests that you could use (Fisher's exact test being one) but another option in R is to simulate the distribution under the null and utilize this empirical distribution to calculate the p-value.
mat <- matrix(data = c(84, (99 - 84), 105.5, (146 - 105.5)), ncol = 2)

chisq.test(x = mat, correct = FALSE)

chisq.test(x = mat, correct = TRUE)

chisq.test(x = mat, simulate.p.value = TRUE)

Without the continuity correction, the p-value is 0.021. With the continuity correction, it's 0.031. Simulating the distribution produces a p-value of ~ 0.026. (One issue with this approach is that in R this simulation samples from a hypergeometric distribution which may not approximate your sampling situation.)
For other good threads on this see: Yates continuity correction for 2 x 2 contingency tables and Given the power of computers these days, is there ever a reason to do a chi-squared test rather than Fisher's exact test?
