McNemar's test

Let’s say we’re interested in the effect of smoking on low infant birthweight, where “low infant birthweight” is an indicator based on birthweight falling below 2500 grams. In an experimental study, we would randomly assign expectant mothers to either smoke or not smoke, record their infant’s birthweight, and then compare the proportion of low birthweights between the two groups. Obviously that would be unethical and no review board would approve such a study. We also probably wouldn’t get many participants.

There are many medical tests for detecting the presence of a disease or condition. Some examples include tests for lesions, cancer, pregnancy, or COVID-19. While these tests are usually accurate, they’re not perfect. In addition, some tests are designed to detect the same condition, but use a different method. A recent example are PCR and antigen tests for COVID-19. In these cases we might want to compare the two tests on the same subjects. This is known as a paired study design.