I seek a textbook example of the application of chi square tests for main effects and interaction for categorical data, as in a 2x6 table. I plan to use this to help me be sure I can correctly use CTABLES in SPSS.
-
I’ve made an assumption that you know how to F-test analogously in the case of linear regression. Please say if that part is unclear, because my answer will not make sense until that is clear. – Dave Feb 02 '22 at 01:47
1 Answers
A $\chi^2$ test is a score test of nested (multinomial) logistic regression models, one of which just has an intercept and the other of which has a categorical predictor (much like ANOVA is a Wald test of nested linear regression models).
Consequently, if you want to extend this to something like two-way ANOVA with an interaction, you would do a (multinomial) logistic regression with multiple predictors. Then test the parameters with score tests, or “chunk” test to test multiple parameters at once (probably what you want if you have multiple levels in your factor variables).
R has a package that will do the score test for you if you know which regression models to pass in (totally analogous to F-testing nested models on linear regression). If you use another software, it likely has analogous functions.
References
Agresti, Alan. Foundations of linear and generalized linear models. John Wiley & Sons, 2015.
Agresti, Alan. Categorical data analysis. John Wiley & Sons, 2003.

- 28,473
- 4
- 52
- 104
-
My understanding of ANOVA is that there are estimates of variance due to main effects and interaction effect(s) and associated error variances used to test these effects. I am unfamiliar with "nested (multinomial) logistic regression models". Additional explanation would be appreciated. – Joel W. Feb 02 '22 at 16:36
-
@JoelW. Let's start with this: if you had to do two-way testing with interactions for a linear model, how would you do it? ("I don't know," is an acceptable answer.) – Dave Feb 02 '22 at 17:04
-
I would use SPSS to run a 2 way ANOVA, specifying which independent variables is random or fixed. I would look at the table that shows mean squares, degrees of freedom, and significance values for main effects and interaction effects to see which are significant. I would inspect plots of the means. I would also look at the effect sizes for these effects. I may look further, but this is where I would start. – Joel W. Feb 03 '22 at 18:05
-
Hmm. You asked me a question and I responded but I have yet to hear back from you. Why? – Joel W. Feb 06 '22 at 22:52
-
@JoelW. I can’t comment on SPSS, but the R package I linked will do whatever “chunk” test you want. (Remember that ANOVA is one kind of chunk test.) – Dave Feb 06 '22 at 23:45
-
Do you know of a textbook that uses and describes the approach you mention? Or, perhaps, a journal article? – Joel W. Feb 07 '22 at 17:39
-
@JoelW. Agresti, Alan. Foundations of linear and generalized linear models. John Wiley & Sons, 2015. I think the third chapter is when Agresti gets into Wald, likelihood ratio, and score tests of nested regression models. – Dave Feb 07 '22 at 17:47
-
I see he also wrote "An Introduction to Categorical Data Analysis" which has a section on 3 way tables. TY – Joel W. Feb 07 '22 at 22:18
-
@JoelW. Did this answer your question? Perhaps you could consider accepting the answer and awarding the bounty to signal to others that this is helpful. – Dave Feb 09 '22 at 11:11