# What test to compare two dichotomous values?

I have gathered infectious disease incidence data of specific years and categorized that data based on e.g. gender and vaccination status. I test whether there is any difference between the adjacent groups (years) by using Pearson's chi-squared test.

But what test(s) do I use to check whether there is any statistical difference between e.g. gender based on the combined total of all observed years? For instance, if I have 10.000 total cases and 4.500 and 5.500 were male or female, respectively, how do I test whether women are statistically more affected than men? I have now used the binomial test but am not sure if that is correct. Could I use phi coefficient too?

Edit (to clarify what I'm asking here):

Underneath the total amount of men (4705), total amount of women (4531), and the combined total of all cases (9236). I wish to know whether one of the two (in this case men are slightly more frequent) are statistically more likely to acquire an infection. What statistical test do I use for that?

• How did you get the data? The design of the study is important for analysis choice. Commented Dec 21, 2018 at 15:32
• The data is partly from peer-reviewed articles and partly (the years that were not published about) from a data request. This request was honored by the national public health institute. All data that was provided and/or published about is derived from the national surveillance register. Commented Dec 21, 2018 at 15:40
• So this isn't cohort data? You just grabbed a bunch of data from articles and asked some institute for all the cases of this disease? Commented Dec 21, 2018 at 15:45
• I didn't just grab it. The data that I requested is based on years in which incidence was relatively high, but not published on. The data that I got from the articles are outbreak reports that account for >98% of the cases in those years. Years that were not included in the study had an incidence of <50 per year. So no, it isn't cohort data. It's categorized incidence data and I am trying to review all cases and determine trends and characteristics of infected individuals. Commented Dec 21, 2018 at 16:15
• See my answer. I don't know enough about the study design to make a really solid recommendation, but linear regression may be a fine way to go. Commented Dec 21, 2018 at 16:16