I understand chi square tests of independence, and have read the FAQ on chi square tests. What confuses me somewhat is the use of chi square in some instances.

I have always understood a chi square test of independence as being a test of an

*association*-- whether that association is a significant one or not. Or in other words, whether the two variables are found to be independent (i.e. not associated) or dependent (i.e. associated).

And I have always understood that one- and two-sample hypothesis testing involves testing a

*difference*, doing either a Z-test or t-test (depending on the sample size and whether sigma is known or unknown). Therefore, we are testing for if there is a statistically significant difference between a sample value and a population value (one sample test) or if there is a statistically significant difference between two sample values (two sample test).

My confusion arises in that some sources seem to suggest that Chi square tests of independence can allow us to test for a significant difference. For example, let's say we're looking at the following two variables: gender (male or female) and voting preference (democrat or republican). And we want to know if there is a statistically significant difference between the number of women vs. men who vote democrat. I would think you would do a two-sample hypothesis test with sample proportions (males as one sample, females as a second sample), and test for a significant difference in the proportion of men vs women who vote democrat.

But some sources I've read seem to suggest a Chi square test could be done, and we could have a 2x2 bivariate table which includes gender (male or female) or voting preference (democrat or republican). But doesn't chi square test for a significant association between the two variables, not for a difference? Or can we conclude that anyway, that a significant association suggests a difference between males and females? I know that chi square tests for the difference between observed vs. expected frequencies - an indirect test of the association between the variables.

Wouldn't it be more apt to do a two-sample hypothesis test? Particularly, if we were specifying a direction, and we wanted to know if women are

*more likely*to vote democrat, then we would have to do a two-sample hypothesis test, no?

Textbooks I read characterize the chi square test of independence as a test for an association.

I am hoping I am making any sense at all. If anyone can help, I would be greatly appreciative.

Thanks,

Frodo