The world is getting fatter, and some say it is also sleeping less. After years of study, we now know that there is a disturbing correlation between those factors. Those who sleep less have a higher chance of being obese.

If how much you sleep can affect what you eat (and thus make you fat), many sleep scientists wonder whether the reverse is also true. That is, could what you eat affect how you sleep?

This is the question sleep scientist Marie-Pierre St-Onge and her colleagues at Columbia University sought to answer. The team’s results of a clinical trial looking at how food consumption can affect sleep and other biological factors have just been published in the Journal of Clinical Sleep Medicine.

For four days, St-Onge subjected 13 men and 13 women to a strict meal and observed their sleeping patterns. This gave her a chance to observe how different people reacted to the same meal. On the fifth day she let them eat whatever they wanted, and then she observed how each of them slept after their happy meal.

At then end of the week, St-Onge confirmed the hunch. There was a marked difference between how people slept when they ate a controlled diet versus when they ate what they wanted. For instance, on a controlled diet the subjects fell asleep in about 17 minutes. But when they ate what they wanted, it took them nearly twice as much time.

Those who ate more fiber in their meals, spent more time in slow-wave sleep, which is the constructive phase of sleep. Those who ate more fat, had the exact opposite effect. And those who ate more carbohydrate were more prone to waking up at night.

St-Onge speculates the reason for such drastic changes might be because of how food affects our body clock. Previous studies have shown that eating carbohydrates, for instance, affects our circadian rhythm, raises body temperature, and reduces the secretion of sleep-inducing melatonin.

Though the clinical trial was conducted on small number of subjects, its results are more reliable because of the strict conditions in which the study was performed. Subjects were carefully selected to be representative of average human behavior. For instance, before joining the experiment, their sleeping patterns were measured for two weeks using an actigraph to ensure that they slept between seven and nine hours a day.

Previous research has come to similar conclusions to St-Onge’s trial. A 1982 study found those who ate more carbohydrates felt more sleepy, and more recent research showed that the more fat women ate, the less the slept. Yet St-Onge’s work is the strongest indication we have of what we eat affects how we sleep, because it does not suffer from limitations, such as self-reported data, which previous studies are disadvantaged by. Such factors, as Quartz reported earlier, are the bane of sleep research. Although they give hints about larger truths, these studies only strengthen a hunch and don’t actually provide a definite conclusion.

With further investigation, the hope is that dietary changes could be used to treat mild sleep disorders. ”The finding that diet can influence sleep has tremendous health implications, given the increasing recognition of the role of sleep in the development of chronic disorders such as hypertension, diabetes and cardiovascular disease,” St-Onge said.