It’s well known that living in high-poverty neighborhoods has a significant effect on the mental health of children. Now a new study in the Journal of the American Medical Association offers a nuanced look at what happens after children leave these environments. It highlights a paradox: According to the study authors, led by Harvard professor Ronald Kessler, boys who move into more affluent neighborhoods report higher rates of depression and conduct disorder than their female peers.

The reason for the disparity between boys and girls isn’t exactly pinned down. Kessler points to various factors—community perception, interpersonal skills—as major points of influence: “We had an anthropologist working with us, and the anthropologist went and talked to and watched the kids in the old neighborhoods and the new neighborhoods, and their perception was that when the boys came into the new neighborhood they were coded as these juvenile delinquents,” says Kessler. “Whereas with the girls, it was exactly the opposite. They were embraced by the community—‘you poor little disadvantaged thing, let me help you.’”

Kessler’s study was conducted using data from Moving to Opportunity (MTO), a decades-spanning housing mobility experiment financed by the U.S. Department of Housing and Urban Development (HUD). Within this project, 4,604 volunteer families with 3,689 children were randomly divided into three groups. Two of them received different versions of rent-subsidy vouchers that enabled them to move into a better neighborhood. A control group did not move.

In follow-up interviews conducted 10 to 15 years later, boys reported higher proportions of major depression, posttraumatic stress disorder, and conduct disorder than boys within the control group—rates of PTSD comparable to those of combat soldiers. The opposite occurred with girls, who reported mental health that was substantially better than the girls who stayed in high-poverty neighborhoods.

The results represent something of a conundrum. Over the past few decades, urban policy has focused on breaking up clusters of poverty, planning cities so that poor residents could live in areas that also had middle-class people. Does this new research mean projects like MTO are actually a bad thing?