Women in STEM is arguably proof that at least some women can do STEM. It's not even particularly good proof of that. Saying it proves anything more than that is to try to use anecdotal data to prove a statistical argument.
The "black friend" argument is not only that, but worse: It is most commonly heard by people who are willing to make an exception for instances of the demographic I know. "All Foos suck except Murray, he's OK".
Of course, after awhile, if you keep making exceptions, you begin to wonder if your rule has problems. If it turns out that not only is one of your gay friends not a homocidal maniac, but you've actually met lots of gay people and none of them were homocidal maniacs, then maybe, just maybe, not all gays are homocidal maniacs.
So, although "I have a black friend" doesn't mean someone isn't racist, it DOES mean they are probably capable of seeing the light given enough exposure to real black families, etc.
The problem comes when you hit actual differences between, say, races. Blacks are more likely to have sickle cell anemia than whites. That is statistically inarguable, so saying it isn't racist. Whites are more likely to get sun burn. Again, statistically inarguable.
We have gotten to the point, however, where ANY noticed difference causes some people to become downright militant.
Doctors need to know the statistical differences between the races (and genders, and yes, even occasionally creeds). This isn't to say that doctors are never racist, sexist or credist, but to say that differences don't exist becomes a health liability.