1

I have the low expected values problem in my data set and cannot solve with regular methods (e.g. combining levels, etc). I cannot use Fisher's test either because of the fixed marginals assumption of the Fisher's test.

I want to try the permutation test in the chisq.test function in R (that is simulate.p.value option in chisq.test). However, I would like to know whether this simulation assumes fixed marginals in the data or not? (My data is not suitable for fixed marginals assumption, marginals may change depending on the sample taken.)

Jan Kukacka
  • 11,421
oznur
  • 11
  • As the linked duplicate indicates, it uses Patefield's algorithm which samples tables conditional on the margins. That it conditions on the margins is quite explicit in the help: "In the contingency table case simulation is done by random sampling from the set of all contingency tables with given marginals,"; however the fact that your margins are not fixed may be largely beside the point (both for this case and FIsher's exact test); the conditioning is not an assumption about your sampling situation, but relates to inference while conditioning on (almost) ancillary marginal totals... ctd – Glen_b Jul 03 '18 at 12:44
  • ctd... see the discussion of the debate about conditionality here, or see wikipedia here. – Glen_b Jul 03 '18 at 12:50

0 Answers0