I've been recently working with 2x2 contingency tables, where majority of researchers in my field use FET to assess significance. I saw, that in R, one can also use the monte carlo variation of this test.

I can't seem to understand what is being sampled in that scenario, or when is this applicable. To employ FET, one simply counts A=x, A=y, B=x,B=y occurences, and uses that for the exact test. Is the counting part, e.g. |A=x| too computationally demanding? What exactly is being approximated, because even for very large datasets, it is nowdays trivial to count occurrences related to observed event (e.g. disease).

Thank you very much.

*edit 1 The A,B,x and y are labels of rows and columns, the two vertical columns are A,B and the two rows x and y. A=x represents the cell count, A column, x row.

  • $\begingroup$ "A=x, A=y, B=x,B=y" I don't understand what you mean by this. Are you referring to the cell frequencies generated under independence? $\endgroup$
    – AdamO
    Commented Feb 28, 2018 at 15:21
  • $\begingroup$ Yes, sorry for being inconsistent. $\endgroup$ Commented Feb 28, 2018 at 15:49

1 Answer 1


I have misread the documentation regarding FET. It appears my question is valid only when n>2, in that case the permutation part can get computationally expensive, R documentation regarding this parameter explains this nicely:

a logical indicating whether to compute p-values by Monte Carlo simulation, in larger than 2 by 2 tables.

In the r x c case with r > 2 or c > 2, internal tables can get too large for the exact test in which case an error is signalled. Apart from increasing workspace sufficiently, which then may lead to very long running times, using simulate.p.value = TRUE may then often be sufficient and hence advisable.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.