They were also collected from the former cemetery of All Saints by the Castle parish church.
Most of the burials date from the 12-14th century - when the Robin Hood story is set. Those interred within were primarily of a lower socio-economic status, mainly agricultural workers.
The Augustinian friary in Cambridge was an international study house, known as a studium generale, where clergy from across Britain and Europe would come to read manuscripts.
It was founded in the 1280s and lasted until 1538 before suffering the fate of most English monasteries - closed or destroyed as part of Henry VIII’s break with the Roman Church.
The researchers tested 19 monks from the friary grounds and 25 locals from All Saints cemetery.
They found 11 of the friars (58%) were infected by worms, compared with just eight of the general townspeople (32%).
These rates are likely the minimum, and that actual numbers of infections would have been higher.
But some traces of worm eggs in the pelvic sediment would have been destroyed over time by fungi and insects.
Prevalence of parasites among townspeople is in line with studies of medieval burials in other European countries.
It suggests this is not particularly low - but rather the infection rates in the monastery were remarkably high.
Standard sanitation in medieval towns relied on the cesspit toilet - holes in the ground used for faeces and household waste.
In monasteries, however, running water systems were a common feature - including to rinse out the latrine.
That has yet to be confirmed at the site, which is only partly excavated. Not all people buried in Augustinian friaries were actually clergy.
Wealthy people from the town could pay to be interred there. However, the team could tell which graves belonged to friars from the remains of their clothing.
Co author Craig Cessford, of the Cambridge Archaeological Unit, said: "The friars were buried wearing the belts they wore as standard clothing of the order, and we could see the metal buckles at excavation."
Roundworm and whipworm are spread by poor sanitation. Differences in infection rates must have been due to how each group dealt with their human waste.
Dr Mitchell said: "One possibility is the friars manured their vegetable gardens with human faeces, not unusual in the medieval period, and this may have led to repeated infection with the worms."
Medieval records reveal how residents may have understood parasites such as roundworm and whipworm.
John Stockton, a medical practitioner in Cambridge who died in 1361, left a manuscript to Peterhouse college that included a section on De Lumbricis - intestinal worms.
It notes they are generated by excess of various kinds of phlegm. The text said: "Long round worms form from an excess of salt phlegm, short round worms from sour phlegm, while short and broad worms came from natural or sweet phlegm."
It prescribes "bitter medicinal plants" such as aloe and wormwood, but recommends they are disguised with "honey or other sweet things" to help the medicine go down.
Another text - Tabula medicine - found favour with leading Cambridge doctors of the 15th century.
It suggests remedies as recommended by individual Franciscan monks, such as Symon Welles, who advocated mixing a powder made from moles into a curative drink.
Friar Tuck is supposed to have lived in the late 12th and early 13th century - and was portrayed as a Franciscan monk.
There is no evidence he actually existed - although some historians claim Robin Hood is based on an actual person.
A tombstone in Yorkshire reads: "Here underneath this little stone, Lies Robert, Earl of Huntingdon, Ne’er archer was as he so good, And people called him Robin Hood, Such outlaws as he and his men, Will England never see again."
Scottish novelist Sir Walter Scott turned the character into a legend after featuring him in his 1819 masterpiece Ivanhoe. The study is in the International Journal of Paleopathology.
By Mark Waghorn SWNS
Have your say in our news democracy. Click the upvote icon at the top of the page to help raise this article through the indy100 rankings.