I am trying to test the significance of the difference of the

*difference*between two groups (A and B), each defined by two categorical variables, if that makes sense.

For example, I am doing research on black and white patients admitted to a hospital for appendicitis, further stratified by age <50 and age >50. I found that there are proportionally more white patients admitted to the hospital in both age groups, compared to the actual proportion of white patients in that hospital's community.

A - Patients admitted to the hospital (individual patients):

......... | White | Black |

<50 | ..... 67 | ..... 56 |

>50 | ..... 90 | ..... 23 |

B - Ethnic breakup in hospital community:

......... | White | Black |

<50 | 5500 | 5000 |

>50 | 6000 | 5500 |

So, essentially, I would like to test the statistical significance of the difference between A and B (i.e. is the increased proportion of white patients in the hospital compared to the community a significant difference).

I did some reading and am wondering if ANOVA is the right test to use? And if so, I actually have no idea how to organise the data to test (I use the program R).

Any advice in the right direction would be much appreciated!