Getty Images/iStockphoto It's been a doggone day.

Have trouble dozing off at night after a stress-filled day? You're not alone.

Our furry canine pals are also more likely to have a disturbed night's sleep after a day of anxiety, new research has shown.

Hungarian researchers monitored the sleep patterns of pet dogs after "positive" experiences -- like being patted by their owner and playing games -- and "negative" experiences, such as being separated from their owner and approached threateningly by a stranger.

Unsurprisingly, the dogs' personalities affected the way they responded, with more playful pooches less likely to be stressed out by being approached by a stranger than their shyer counterparts.

Hungarian Academy of Sciences The dogs slept better when their human was nearby.

But overall, the doggos who'd been exposed to stressful experiences didn't sleep as well, spent more time in REM sleep (the active sleep stage characterised by increased heart rate) and woke up more quickly.

The findings were published on Wednesday in The Royal Society scientific journal.

Interestingly, the anxious dogs actually fell asleep faster than their chilled-out counterparts, despite not sleeping as well. The researchers attributed this to something called stress-induced quiescence -- a protective sleep in response to stress.

"(This is) a phenomenon that can be induced by several stressors, and that can also be observed as part of the human immune response during sickness," they wrote.

So don't forget to say goodnight to your four-legged pal tonight -- it just might help them sleep tight.

Hungarian Academy of Sciences The dogs' sleep patterns were monitored using non-invasive polysomnography to record their brain waves.

Hungarian Academy of Sciences The happy and contented doggos slept better.