I have this matrix:
x <- c(2, 38, 196, 2)
contingency <- matrix(x, nrow = 2, byrow = TRUE)
print(contingency)
[,1] [,2]
[1,] 2 38
[2,] 196 2
And I've carried out this Fisher's Exact Test:
fisher.test(contingency)
which outputs this:
Fisher's Exact Test for Count Data
data: contingency
p-value < 2.2e-16
alternative hypothesis: true odds ratio is not equal to 1
95 percent confidence interval:
6.103516e-05 4.703333e-03
sample estimates:
odds ratio
0.000701445
My questions are:
The values in the matrix (2, 38, 196, 2) are means. Is it ok to run a Fisher’s Exact Test on these data?
If I was to conclude that the proportions in each group are unlikely to be equal, would i be correct?
Best Answer
The values in the cell of these tables should not be means, they should be counts. Fisher's test is valid only for contingency tables.