We’ve long known that children of color tend to fare poorly in segregated, high-poverty schools. Now, a new study by my colleague Nicole Mader shows that even some of the richest schools in the city don’t bring black and Latino kids up to the level of performance of their white and Asian peers.

This interactive study illustrates the so-called achievement gap at each of the city’s 900 elementary schools, based on the 2016 state math tests for 3rd- to 5th-graders. You can see how kids of different ethnicities fared at your child’s school by typing the school name or number into the search box.

Some of the biggest gaps are in schools that house gifted programs, such as PS 11 in Chelsea and PS 166 on the Upper West Side. These schools have separate “gifted classes,” which admit children who score high on an entrance exam and tend to have mostly white and Asian children. The general education classes have more black and Latino kids. It’s upsetting—but perhaps not surprising—that the test scores reflect the divisions within these schools.

There are big gaps, however, even at some zoned neighborhood schools that mix children of different skill levels in the same classes. For example, PS 183 on the Upper East Side, PS/MS 8 in Brooklyn Heights and PS 29 in Cobble Hill do not separate children into gifted and general education classes. Nonetheless, at these schools, the lower-income black students performed significantly below their white and Asian classmates. These three schools have some of the richest PTAs in the country, according to a report last year by the Center for American Progress.

A handful of schools buck the trend of low performance in high-poverty schools: Success Academy charter schools consistently post very high test scores, as does PS 359, also called Concourse Village School, in the South Bronx.

Nicole’s report doesn’t explore why gaps exist at some schools and not others. From what I’ve seen on my school visits, the Success Academy Charter Network combines lots of test prep with a thoughtful, well-crafted math curriculum. It also has a policy of holding back children in 2nd grade who are not ready for the 3rd grade test; its strict disciplinary policies, moreover, may weed out low-performing children. Millions of dollars in private philanthropy give Success schools greater resources than other schools in low-income neighborhoods have.

What explains the disparities in the rich schools? The effects of poverty, stress and trauma outside the school buildings play a role. Research also shows that subtle bias and racial stereotypes can raise anxiety in a test-taker’s mind and result in lower scores.

“There are subtle things that happen within a building,” said Maya Wiley, a professor of urban policy at The New School. “Teachers are really not aware that they have stereotypes about kids.” A curriculum that is more responsive to cultural differences can make a difference, as one recent study shows.

It’s clear that just having children of different races and ethnicities in the same classroom isn’t enough to make sure all succeed. This is a sobering lesson for all of us who care about fairness and equity.