3
$\begingroup$

As a follow up to my previous question, I learned that the chi square test can be used to compare expected and observed frequency distributions. But...

Suppose I have the following data table in CSV, which surveys people on their fruit preferences in three cities (total people surveyed is different in each city):

apples,oranges,grapes,bananas

Acme Acres,5,15,5,15

Redmond,2,3,16,0

Cupertino,9,13,8,4

(1) I can run a chi-square test on each city, to see if my observed frequencies are significantly different from expected (in this case, equally distributed). But is there a test that I can run on ALL THREE cities at once to see if they are different from each other, AND also if they are individually different from the expected equal distribution?

(2) If I can run a test that says there is a difference between cities, and/or if each one is different from the expected distribution, is there an equivalent of the Tukey test where I can see which specific fruits are the ones that are different?

Thanks!

$\endgroup$
4
$\begingroup$

With this many questions to ask of the data, you are approaching the border between a "test" and a "model" (not that such a sharp distinction exists except in the conceptualization of the problem).

A Poisson regression model, aka log-linear model, can answer these questions for you. The book The analysis of crossclassified data by Stephen Fienberg explains this family of models.

| cite | improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.