Remember when the Bills were 3-1 and in first place in the AFC East? And when the Patriots were 2-2 and allowing 32 points per game? Weird, right?

The Bills part, yes. The Patriots part, no.

New England had done that before. Four other times in the Bill Belichick era. It made the playoffs each time. It won the Super Bowl twice.

So here we are. The Patriots are in the Super Bowl again — their eighth since 2002. The Eagles are in the Super Bowl again, too — their first since 2005, when they lost to … the Patriots. It’s Tom Brady (36 postseason starts) vs. Nick Foles (42 regular season and postseason starts). A surgical New England offense vs. a tough Philadelphia defense.

Who has the edge? Let’s dive into the numbers to find out.

(Statistics below are from the regular season only.)

The traditional way to rank NFL teams is by their yards gained and yards allowed, but yardage doesn’t always accurately reflect the quality of a team. What if, for example, a team racks up a lot of yardage because its schedule happened to feature a lot of soft defenses? How do we account for that?

This is where Football Outsiders comes in. To better measure team performance, they developed a statistic they call Defense-adjusted Value Over Average or DVOA. DVOA takes every play and compares a team’s success on that play with the league average. Think of it as a measure of team efficiency.

DVOA is adjusted for situation and opponent and is expressed as a percentage, where a positive percentage indicates an above-average performance and a negative percentage indicates a below-average performance. So if a team has a DVOA of 10 percent, that means it played 10 percent above the league average. (When separating DVOA by offense and defense, the best offenses have a positive rating and the best defenses have a negative rating.)

Overall, the Patriots and Eagles appear to be evenly matched. When we look at their seasons more closely, however, a significant difference emerges. New England had the NFL’s most efficient offense, but its defense was among the least efficient. Only Tampa Bay ranked lower. Philadelphia was not as efficient offensively, but it ranked in the top 10. We should be careful not to place too much weight on that, however, because Carson Wentz, who suffered a season-ending knee injury in Week 14, was responsible for much of that success. On defense, the Eagles are at the other end of the spectrum from the Patriots. They fielded one of the league’s stingiest units.

Brady turned in a typical Brady season. He threw for more than 4,500 yards. He threw more than 25 touchdown passes for the 13th time, most among active players. He threw single-digit interceptions for the fourth straight season.

Foles stepped in for the Eagles after the Wentz injury. If you throw out a meaningless Week 17 loss, Philadelphia has yet to lose with him as the starter (4-0). That’s mostly a credit to the defense, which forced three turnovers and scored a touchdown Sunday. You wouldn’t know it from watching the Eagles’ blowout of the Vikings, but Foles can be shaky, especially when under pressure, and sometimes has trouble pushing the ball down the field.

Both teams finished in the top five in points allowed, but they did so in very different ways. The Eagles have the championship-caliber defense. They can pressure the quarterback and defend both the pass and the run well, though they’re best at containing the run (3.8 yards per carry, sixth best). The Patriots’ weakness is their pass rush, but they make up for it because they force their opponents to drive longer than anyone else. They led the NFL this season in average opponent starting field position.

The Patriots have been the more disciplined team, particularly on defense, where they drew 29 penalties, second to only the Giants. The Eagles had 50. Offensive penalties are the ones to watch, though. According to Football Outsiders, teams with more offensive penalties generally lose more games. FO’s research found no correlation between defensive penalties and losses.

Eagles 20, Patriots 17

Statistics in this report are from Football Outsiders, Pro Football Focus and Pro Football Reference. Photographs are from the Associated Press and Getty Images. Contact Thomas Bassinger at [email protected] Follow @tometrics.