This chapter describes graphical models for multivariate discrete (categorical) data. It starts out by describing various different ways in which such data may be represented in R—for example, as contingency tables—and how to convert between these representations. It then gives a concise exposition of the theory of hierarchical log-linear models, with illustrative examples using the gRim package. Topics covered include log-linear model formulae, dependence graphs, graphical and decomposable models, maximum likelihood estimation using the IPS algorithm, and hypothesis testing. Model selection is briefly discussed and illustrated using a stepwise algorithm. Graphical modeling is particularly useful for multi-dimensional tables, and since these are often sparse, it is necessary to adjust the degrees of freedom as normally calculated. Other topics treated in the chapter include exact conditional tests, ordinal categorical variables, and a comparison of fitting log-linear models using IPS and the glm algorithms. A final section describes some utilities for working with the models.
[1]
T. Schoener.
The Anolis Lizards of Bimini: Resource Partitioning in a Complex Fauna
,
1968
.
[2]
G. Koch,et al.
Analysis of categorical data by linear models.
,
1969,
Biometrics.
[3]
H. Akaike.
A new look at the statistical model identification
,
1974
.
[4]
Stephen E. Fienberg,et al.
Discrete Multivariate Analysis: Theory and Practice
,
1976
.
[5]
G. Schwarz.
Estimating the Dimension of a Model
,
1978
.
[6]
J. N. R. Jeffers,et al.
Graphical Models in Applied Multivariate Statistics.
,
1990
.
[7]
Brian D. Ripley,et al.
Pattern Recognition and Neural Networks
,
1996
.
[8]
Jens Henrik Badsberg,et al.
A Guide to CoCo
,
2001
.