Laying bare supply and demand in the oldest profession.

It's hard out here for a pimp," complains the Three 6 Mafia, a rap group. A new study by the Urban Institute, a think-tank, casts doubt on this assertion. After investigating the sex trade in eight big American cities, researchers concluded that pimps can do rather well for themselves. Some in Atlanta bring in $33,000 a week, the study estimates.

Tracking the sex trade is hard. It is legal only in parts of Nevada. Elsewhere there are no receipts; researchers relied instead on interviews with lawyers, police, prostitutes and pimps. Their fat report, commissioned by the Justice Department, brought squeals of pleasure from journalists everywhere, who tended to play up evidence that the oldest profession is booming.

But it doesn’t appear to be. In five out of seven cities, the underground sex industry shrank between 2003 and 2007, the study found. (In one place, Kansas City, Missouri, there was not enough evidence to decide.) In Washington, DC, takings fell by 34%. In Denver, with a population of 2.5m in 2007 if you include the suburbs, the sex trade grossed a mere $40m.

The demand for sex probably does not change much over time, but other things do. A century ago, when sexual mores were stricter, prostitution was more common and better paid (see table). Men’s demand for commercial sex was higher because the non-commercial sort was harder to obtain--there was no premarital hook-up culture. Women were attracted to prostitution in part because their other job opportunities were so meagre. And they commanded high wages partly because the social stigma was so great--without high pay, it was not worth enduring it.

The price for a trick today ranges from miserable ($15) to ample ($1,000 or more). Prostitutes have many options besides street-walking. The internet makes it easier for them to set up "dates" and negotiate prices, and harder for the police to catch them. They feel less vulnerable using social-media sites than doing the "stroll". But 36% nonetheless report that some clients were violent or abusive.

Pimps, who are often women, tend to follow a business plan. They impose rules, such as "no drugs" or "no young clients" (who are more likely than older men to be violent). They are flexible with pricing, offering special deals for loyal customers and swiftly adapting to economic downturns. A third of pimps delegate management, training and even recruitment to an experienced employee called a "bottom girl". About 15% admitted to beating up their staff. Others, however, thought violence was bad for business. One pimp said: "One bad girl can knock your whole stable loose. Get rid of the bad apple. If I needed to hit them, I didn’t need them."

Click here to subscribe to The Economist.