assocstats {vcd} | R Documentation |
Computes the Pearson chi-Squared test, the Likelihood Ratio chi-Squared test, the phi coefficient, the contingency coefficient and Cramer's V.
assocstats(x)
x |
an r x c table. |
A list with components:
chisq_tests |
a 2 x 3 table with the chi-squared statistics. |
phi |
The phi coefficient. |
cont |
The contingency coefficient. |
cramer |
Cramer's V. |
David Meyer David.Meyer@R-project.org
Michael Friendly (2000), Visualizing Categorical Data. SAS Institute, Cary, NC.
data("Arthritis") tab <- xtabs(~Improved + Treatment, data = Arthritis) summary(assocstats(tab))