# Seeing if (and *how*) two categorical variables are related

Consider the variables sex (male or female) and political party affiliation (Democrat or Republican). In this case, the null hypothesis and alternative hypothesis would be:

• H0: Sex is independent from political party affiliation.
• H1: Sex and political party affiliation are related.

I understand that a chi square test of independence can be used if I'm checking whether two categorical variables are dependent, so that's what I would use here.

However, what if I want to perform a test such as the below:

• H0: Sex is independent from political party affiliation.
• H1: Men are more likely to be democrats than women.

Chi square only tests for independence so I feel like it wouldn't provide enough information. But then what kind of test could be used here? How would one go about solving this problem?

• @twix In my first year stats class, we covered one-tailed categorical tests. It's nothing to do with the asymmetry of the $\chi^2$ distribution, rather there's just the added nuance of actually looking at the direction of association. The normal approximation to proportion test is more intuitive, and you should probably use it. Jun 1, 2021 at 21:42