Researchers in Britain have revealed that they are studying a rare tapeworm that lived in a man's brain for four years.
The parasite travelled five centimetres (two inches) from the right side of the brain to the left.
The tapeworm causes sparganosis, an inflammation of body tissues that can cause seizures, memory loss and headaches when it occurs in the brain.
Surgeons removed it and the patient is now "systemically well", the Wellcome Trust Sanger Institute said.
It was the first time the tapeworm, Spirometra erinaceieuropaei, was reported in Britain. Only 300 cases have been reported since 1953.
The tapeworm is thought to be caught by accidentally eating small infected crustaceans from lakes, eating raw amphibian or reptile meat, or by using a raw frog poultice which is a Chinese remedy for sore eyes.
"We did not expect to see an infection of this kind in the UK, but global travel means that unfamiliar parasites do sometimes appear," said Effrossyni Gkrania-Klotsas of the department of Infectious Disease at Addenbrooke's NHS Trust.
The team managed to sequence the rare parasite's genome for the first time, allowing them to examine potential treatments.
"Our work shows that, even with only tiny amounts of DNA from clinical samples, we can find out all we need to identify and characterise the parasite," Gkrania-Klotsas added.
The doctor said the DNA study underlined the importance of a global database of worm genomes, to help identify and treat parasites.