Examining animal droppings is not glamorous—even if you’re studying vampires. But, for scientists interested in the diet of the common vampire bat (Desmodus rotundus), it’s one of the few ways to learn what they eat. In a new study, researchers used DNA found in the bats’ feces to learn whose blood they suck and which blood they like best. The team discovered that although chicken DNA was most frequently found, it’s pigs that the bats seem to crave.

“This project that they did was my dream,” says Gerry Carter, a University of Maryland, College Park, graduate student who was not involved in the new research and who tackled a similar problem as an undergraduate. “I wanted to go to the Amazon and apply this technique. Ten years later, to see this applied in the field is great.”

Bat biologists have previously observed the nocturnal mammals feeding on many prey species, but it’s hard to measure what the bats prefer. That’s partly because the bloodsuckers don’t leave any hard evidence in their droppings, such as small bones or partially digested bits of prey.

Scientists at the National Institute of Amazonian Research in Manaus, Brazil, looked instead for clues in DNA. The team modified an existing technique to isolate and then amplify the genetic material of five potential prey species in bat scat: chickens, pigs, dogs, cattle, and humans. The researchers spent 47 nights in 18 villages in the Amazon and captured 157 vampire bats to collect fecal samples. “It's surprising that you can even get DNA out of this,” Carter says, adding that very little genetic material survives digestion. “It's a particularly difficult sample to work with.” Refrigerating the samples shortly after capture was key to making a positive ID. In spots with no electricity, many samples were too degraded to make a match.

More than 60% of the viable samples contained chicken DNA, with pig DNA showing up in about 30%. But to determine which prey the bats preferred, the researchers had to account for the fact that there were fewer pigs than chickens in the villages where they collected samples. After controlling for the availability of the animals, the scientists calculated that vampire bats were seven times more likely to feed on pigs than chance would predict, the team reports in the current issue of the Journal of Mammalogy. The researchers speculate that the preference is due to the bats’ saliva, which is better at liquefying mammal blood than bird blood. In addition, pigs had the highest concentration of red blood cells.

The scientists also checked the samples for DNA from wild prey in the forests around the villages, but they found only DNA from domesticated animals. That’s likely because those animals were easier targets, the paper reports.

Although no evidence of human DNA was found in the wild bats, Carter adds that sleuthing fecal DNA could be important for understanding the bats’ role in transmitting the rabies virus. The bats caused 25 deaths from rabies in northern Brazil between 2004 and 2005, the paper reports.