Learn & Understand

Paired Categorical Data: Why Only the Changes Carry Information

In a hurry? Skip straight to the numbers.

Open the McNemar Calculator →

The companion calculator performs McNemar's test, which examines paired before-and-after categorical data and deliberately ignores everyone whose classification stayed the same, focusing entirely on those who changed. That decision, to look only at the "discordant pairs," reveals a deep and counterintuitive principle about measuring change: when you want to know whether something shifted, the people who did not change tell you nothing, and only the changers carry the information. Understanding why paired categorical data is special, why only the discordant pairs matter, and the logic of measuring directional change turns a McNemar calculation into an appreciation of a subtle idea about where information lives.

The Special Structure of Paired Data

McNemar's test applies to paired categorical data: the same subjects measured twice on a binary outcome, so each subject provides a before and an after classification, and the pairing links the two measurements. This is different from comparing two separate groups; here, each subject is their own before-and-after comparison, and the question is whether the classification tends to change in one direction more than the other between the two measurements, as the calculator describes for before/after binary outcomes. The pairing is what makes the data special: because the same subjects are measured twice, the comparison controls for the individual characteristics that stay constant, isolating the change itself. The data naturally sorts subjects into those who were classified the same both times (concordant) and those whose classification changed (discordant). Understanding the special structure of paired categorical data is the foundation for McNemar's test: it is designed for repeated measurements on the same subjects, where the object of interest is the pattern of change between the two measurements, not the overall counts. This structure, subjects paired with themselves across two measurements, is what enables the test's focus on change and its counterintuitive disregard for the unchanged, which is the key to its logic.

Why the Unchanged Tell You Nothing

McNemar's test ignores the subjects whose classification stayed the same because, for the question of whether change goes more in one direction, those subjects carry no information, only the changers do.

Which subjects carry information about change
Subject typeInformative about directional change?
Stayed the same (concordant)No: no change to reveal direction
Changed (discordant)Yes: their direction of change is the evidence

A subject who was classified the same way both times did not change, so they provide no evidence about whether change tends to go from one category to the other, they are consistent with any answer to that question and contribute nothing to detecting a directional shift. The subjects who did change, the discordant pairs, are the only ones whose data bears on the question: among them, the test compares how many changed in each direction, and if changes go predominantly one way more than chance would predict, that is evidence of a real directional shift, as the calculator computes from the two discordant counts. This is why McNemar's test focuses entirely on the discordant pairs and disregards the concordant ones: the information about directional change lives entirely in the subjects who changed. Understanding why the unchanged tell you nothing is the counterintuitive heart of the test: it feels natural to use all the data, but for measuring the direction of change, the subjects who did not change are irrelevant, and including them would only dilute the signal. The calculator uses only the discordant counts; understanding why the concordant subjects are uninformative is what reveals the logic of focusing on the changers.

The Logic of Measuring Directional Change

The deeper principle McNemar's test embodies is that measuring change requires looking at what changed, and specifically at the balance of directions among the changes. Once attention is restricted to the discordant pairs, the question becomes simple: did more subjects change from one category to the other than in the reverse direction, by more than chance would produce? If changes were purely random, they would go roughly equally in both directions, so a systematic imbalance, many more changing one way than the other, indicates a real effect pushing the change in that direction, as the calculator's example shows a significant shift when one direction of change dominates. This is the logic of measuring directional change: compare the counts of the two kinds of change, and a lopsided balance signals a genuine directional effect. The test essentially asks whether the changes are symmetric (equally likely in both directions, consistent with no real effect) or asymmetric (favoring one direction, indicating an effect). Understanding the logic of measuring directional change reveals what McNemar's test actually tests: not the overall proportions, but the symmetry of the changes among those who changed, which is the precise question of whether an intervention or event shifts subjects one way more than the other. The calculator compares the discordant counts; understanding this logic is what reveals why the test's focus on the direction of change among the changers is exactly the right way to detect a directional effect in paired categorical data.

Why This Design Is Powerful

The paired design that McNemar's test analyzes is powerful because pairing subjects with themselves controls for individual differences, making the test sensitive to change that a between-groups comparison would obscure. Because each subject serves as their own baseline, the many individual characteristics that differ between people and that stay constant across the two measurements are automatically accounted for, they cannot contribute to the observed change, so the comparison isolates the effect of whatever happened between the measurements. This within-subject control removes a major source of variation, making the paired design more sensitive to detecting real change than comparing separate groups, where individual differences add noise. Focusing on the discordant pairs sharpens this further by zeroing in on exactly the subjects who reveal the effect. This is why paired and matched designs are valued throughout statistics: they reduce the variation that obscures effects, and McNemar's test applies this principle to categorical before-and-after data. Understanding why this design is powerful completes the picture: pairing controls for individual differences, focusing on the changers isolates the information about directional change, and together they make McNemar's test a sensitive, efficient way to detect whether a categorical outcome shifts in one direction. The calculator implements this test; understanding the power of the paired design and the logic of focusing on the discordant pairs is what reveals why measuring change this way, by attending only to those who changed and the direction they changed, is both counterintuitive and exactly right.

Understanding McNemar's Test

Use the calculator to perform McNemar's test, and understand its logic: paired categorical data measures the same subjects twice, and the test focuses only on the discordant pairs, those who changed, because the unchanged subjects carry no information about the direction of change. It detects whether changes favor one direction more than chance, and the paired design's control of individual differences makes it powerful. The calculation uses the discordant counts; understanding why only the changes matter is what reveals the elegant logic of measuring directional change in paired data.

Ready to Put This Into Practice?

Now that you understand how it works, plug in your own numbers and get an instant, accurate result.

Use the McNemar Calculator Now →