Among those with a college degree, 17 percent of those who tied the knot after they graduated were obese, compared with 24 percent of those who got married first. There was a smaller, but still significant, effect found for the timing of children: People who had kids before college were more likely to be obese.

Importantly, the authors controlled for the participants’ parents’ socioeconomic status and for their BMI before they reached college age. In other words, these individuals weren’t more likely to be obese to begin with: The marriage timing definitely had something to do with the weight gain.

But what was it, exactly?

The study didn’t aim to find a reason, but the researchers proffer one theory, which is that college gives us critical-thinking skills that helps manage weight under changing circumstances. (That might help explain why college-educated people tend to be thinner in general.)

People who get married before they acquire those skills have already transitioned into their adult social roles—and might have already adopted all the unhealthy eating habits of married life. College-educated spouses also make more money, so they can afford the Pilates classes and kale chips that help guard against obesity.

“People who earn a college degree before getting married are more likely to have developed problem-solving skills that allow them to overcome obstacles that may prevent them from exercising and eating healthy as they adjust to married life,” Miech said in a statement. “On the other hand, our research suggests that people who earn a college degree after marrying may have established exercise and diet habits that are more difficult to change later.”

It’s hard to know exactly how to harness this finding to help society—people do (and should!) get married whenever they want to, after all. But it is a powerful illustration of just how difficult it is to stay healthy in today’s Doritos-Locos-Tacos world. You literally need a college degree, it seems, to avoid the minefield of food temptations that crop up once you settle into domesticity.