Where do our thoughts go when we die? If you’re lucky, they stay put for a bit.

Canadian doctors studying brain activity in recently dead patients found that humans don’t always stop thinking when our hearts stop beating. One of the patients’ brains remained active for more than 10 minutes after he or she was considered clinically dead. The activity was similar to that of a deep sleep.

It’s a big change from what researchers previously thought, based on a study of decapitated rats, who experienced a huge surge of activity in the minute after they met their gruesome fate. But the new findings, reported in a study published by doctors at the University of Western Ontario, indicate that for humans, brain activity is much more complicated.

The study looked at four critically ill patients who had just been taken off life support in an ICU in Ontario. Each patient experienced different levels of brain activity in the moments before and after they died. Some even ceased thinking before they died.

But one patient mysteriously experienced a surge of activity both before and after he or she died. The period of activity after doctors declared the patient died lasted a baffling 10 minutes and 38 seconds, the study reported.

Sure, it was a small sample, the doctors noted in their findings, but it points to a need for further research of brain activity after death, especially considering the ethics surrounding organ donation.

They also suggested that the surge in brain activity prior to death could provide a warning sign that death is near, they said.