It’s impossible to avoid the apartment affordability topic these days. As industry players cautiously look for a possible inflection point amid near-unprecedented good times, talk of rising rents and stagnant incomes always comes up. The fire is fueled by breathless press releases and blog articles by various research shops and economists trumpeting that apartment rents are unaffordable and that home purchase has never looked better.

But there’s a problem with these assumptions: bad math.

The idea that the conventional, market-rate apartment market is anywhere near an affordability crisis—or that owning is cheaper than renting in many markets—is simply wrong.

Just the Facts
Here are the facts: The median market-rate apartment household pays 21% of its income toward rent. This statistic comes directly from property managers’ rent rolls, extracted by MPF Research from the millions of units serviced by RealPage software. The publicly traded REITs have all reported similar numbers, ranging from the high teens to the low 20s. That’s nowhere near the unaffordability threshold, which most economists pin at 30%.

But the rent-to-income number alone doesn’t tell the full story. It’s important to also look at retention rates. Are rising rents leading to more vacancies? No; vacancy levels are near record lows. Are rising rents forcing renters to move out in big numbers? Again, no; the daily rent roll data on millions of units tracked by MPF show that retention rates are actually climbing. In 2015, 52% of renters with expiring leases signed renewals. That’s unusually high, and it’s up 80 basis points year over year. Retention rates have now increased in five of the past six years, in fact. Additionally, the public REITs are reporting declines in unpaid rent.

Given these facts, how has the narrative of a runaway affordability crisis become a widely held belief—a topic mentioned at every industry event and every CNBC interview with a real estate economist? To answer that question, let’s look at the math.

Re-examining the Numbers
To calculate the rent-to-income ratio, the number everyone uses comes from the federal government. The median annual household income nationally is about $54,000, or $4,500 per month. The average market-rate apartment goes for about $1,240. Put the two together, and you have a rent-to-income ratio of 28%. (Some economists prefer the median rent, but unlike with home prices, medians and averages are similar for apartments, so the results don’t change much.)

Here’s the first flaw: It’s apples and oranges. The median U.S. household isn’t the median market-rate apartment household. Only about 10% of American households live in market-rate apartments, and the data tell us this is somewhat of a privileged class. MPF’s data from rent rolls look only at households that actually live in apartments. This group commands incomes 22% above the U.S. median—despite skewing younger in age.

The second flaw is related to the first: You can’t take the medians from two separate data sets (or two separate groups of households) and mash them together. To accurately gauge what the median apartment household pays toward rent, you have to know the rent-to-income ratio for each apartment household, and then take the median ratio.

Anyone still worried about an affordability crisis should read through earnings-call transcripts from the public REITs. What’s remarkable—and really speaks to the “privileged class” theory for those who live in market-rate apartments—is that most REITs report little to no growth in rent-to-income ratios for new residents. This isn’t to argue that no one is moving out due to rent hikes. But putting together real data with anecdotal reports from apartment operators tells us it’s not a widespread problem.

One last point on bad math: A prominent housing research group last year announced it was much cheaper to buy than rent in most markets. The “study” was widely picked up by the media. Yet its conclusion was based on a number of flawed assumptions, most notably that homeowners don’t pay taxes, insurance, or maintenance costs … and that home buyers are making a 20% down payment, when the reality is that most buyers put down much less.

The True Affordability Crisis
The unfortunate consequence of this bad math is that public sympathies have been misdirected. The real crisis is the nation’s severe shortage of designated affordable housing units serving a growing number of low-income households. These are renters who couldn’t afford market-rate apartments even prior to recent rent hikes. The Joint Center for Housing Studies at Harvard University, in its 2015 report, estimated that for every 100 very low-income renters in the country, there are only 58 affordable units available.

This topic is gaining steam, becoming a major focal point for the National Multifamily Housing Council and its president, Doug Bibby. But there’s no quick fix. Affordable housing development requires tax subsidies to be feasible, and anyone who’s navigated the bureaucratic red tape will tell you that’s a major challenge.

It’s usually a local government issue, and every municipality has different policies and different interest levels in such projects. And at the federal level, housing policy is overwhelmingly bent in favor of moving renters into homeownership, not creating affordable housing for the huge number of Americans who couldn’t afford to buy a home even under the most generous terms.

Bad math has its consequences.