Abstract
We present a Markov chain Monte Carlo (MCMC) method for generating Markov chains using Markov bases for conditional independence models for a four-way contingency table. We then describe a Markov basis characterized by Markov properties associated with a given conditional independence model and show how to use the Markov basis to generate random tables of a Markov chain. The estimates of exact p-values can be obtained from random tables generated by the MCMC method. Numerical experiments examine the performance of the proposed MCMC method in comparison with the χ 2 approximation using large sparse contingency tables.
Similar content being viewed by others
References
Agresti A (1992) A survey of exact inference for contingency tables. Stat Sci 7: 131–153
Agresti A (1999) Exact inference for categorical data: recent advances and continuing controversies. Stat Med 20: 2709–2722
Booth JG, Butler RW (1999) An importance sampling algorithm for exact conditional test in log-linear models. Biometrika 86: 321–332
Caffo BS (2006) Exact hypothesis tests for log-linear models with exactLoglinTest. J Stat Softw 17: 1–17
Caffo BS, Booth JG (2001) A Markov chain Monte Carlo algorithm for approximating exact conditional probabilities. J Comput Graph Stat 10: 730–745
Christensen R (1997) Log-linear models and logistic regression, 2nd edn. Springer, New York
Dalenius P, Reiss RS (1982) Data-swapping: a technique for disclosure control. J Stat Plan Inference 6: 73–85
Darroch JN, Lauritzen SL, Speed TP (1980) Markov-fields and log-linear models for contingency tables. Ann Stat 8: 522–539
Dawid AP (1979) Conditional independence in statistical theory (with discussion). J R Stat Soc Ser B 41: 1–31
Diaconis P, Sturmfels B (1998) Algebraic algorithms for sampling from conditional distributions. Ann Stat 26: 363–397
Dobra A (2003) Markov bases for decomposable graphical models. Bernoulli 9: 1093–1108
Edwards D (1995) Introduction to graphical modelling. Springer, New York
Forster JJ, McDonald JW, Smith PW (1996) Monte Carlo exact conditional tests for log-linear and logistic models. J R Stat Soc Ser B 58: 445–453
Geyer CJ (1992) Practical Markov Chain Monte Carlo. Stat Sci 7: 473–483
Goorin AM, Perez-Atayde A, Gebhardt M, Andersen JW, Wilkinson RH, Delorey MJ, Watts H, Link M, Jaffe N, Frei E III (1987) Weekly high-dose methotrexate and doxorubicin for osteosarcoma: the Dana-Farber Cancer Institute/the Children’s Hospital–study III. J Clin Oncol 5: 1178–1184
Hastings WK (1970) Monte Carlo sampling methods using Markov chains and their applications. Biometrika 57: 97–109
Lauritzen SL (1996) Graphical models. Oxford University Press, New York
Sundberg R (1975) Some results about decomposable (or Markov-type) models for multidimensional contingency tables: distribution of marginals and partitioning of tests. Scand J Stat 2: 71–79
Author information
Authors and Affiliations
Corresponding author
Additional information
This research is supported by the Japan Society for the Promotion of Science (JSPS), Grant-in-Aid for Scientific Research (C), No 20500263.
Rights and permissions
About this article
Cite this article
Kuroda, M., Hashiguchi, H. & Nakagawa, S. Computing p-values in conditional independence models for a contingency table. Comput Stat 25, 57–70 (2010). https://doi.org/10.1007/s00180-009-0161-0
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00180-009-0161-0