Not getting enough sleep can make us feel a lot of things, but more than anything else it can make us feel super emotional, according to a new study published in the Journal of Neuroscience.

Up until now, researchers didn’t know how exactly sleep deprivation affected our emotions. Study author Talma Hendler of Tel Aviv University in Israel told New Scientist that she was particularly interested in “how lack of sleep leaves us with a short emotional fuse.” So she and her team kept 18 adults awake all night, which, as one would imagine, was no small feat.

Participants were given two rounds of tests while undergoing brain scans both during their all-nighter and the day after a good night’s sleep. New Scientist reported that one of the tests asked participants to describe which direction yellow dots were moving, in which the dots were laid over distracting images. These images could be “positively emotional” (cat photos), “negatively emotional” (a mutilated body), or neutral (a spoon).

Researchers found that when participants got a good night’s sleep, they were quicker and better at telling the direction of movement when the dots were over a neutral image. Without sleep, however, participants performed equally bad when the dots were over neutral and emotional images. Hendler said it could be sleep deprivation “universally impairs judgment,” but it could also be “that lack of sleep makes neutral images suddenly provoke an emotional response.”

To further their study, researchers conducted a second experiment that involved participants being shown neutral and emotional images while inside an fMRI scanner. This time, as participants completed a task, researchers could measure activity in different areas of the brain. And like the first experiment, researchers found that sleep deprived participants were distracted by every image whereas non-sleep deprived participants were only distracted by emotional images.

In the brain, the amygdala — a region associated with emotion — was activated when non-sleep deprived participants were seeing emotional images. Among those who were sleep deprived, the amygdala fired up in response to neutral and emotional images. What’s more is researchers found unusual activity in the anterior cingulate cortex, a brain region believed to regulate the amygdala.

These parts of the brain usually “fire together,” New Scientist reported; without adequate rest, these brain regions fire out of sync. As a result, Hendler said it’s harder to control our emotional responses.

“You lose neutrality,” Hendler added. “The ability of the brain to tell what’s important is compromised — it’s as if everything is important.”

The solution, of course, is obvious: try to get some sleep. Medical Daily has previously reported on some sleep hacks, here, here, and here. If not for better control of emotions then for the fact that sufficient sleep can help you avoid a host of health problems.

Source: Hendler T, et al. Losing Neutrality: The Neural Basis of Impaired Emotional Control without Sleep. Journal of Neuroscience. 2015.