There are economic factors associated with being a primary educator. The pay, for lack of a better way to put it, sucks. This impacts men and women.
My wife and I went through Physics grad school together. To say that the experience was hostile for her, and many other women, would be an understatement.
My daughter is contemplating grad school for next year (senior in college, its been an interesting year). We've been open/honest about the challenges she'll face in Physics, but the state of things is much better now than it was when we went through 30 years ago (ouch). Given that she runs circles around most of her fellow students, I'm not the least bit worried on the academic side.
My concern, as all fathers of exceptional daughters should be (I guess that's all of us?) is the cultural aspects of programs, and potential jobs. I use the word "place" below to discuss grad school and/or jobs.
If the place is overtly hostile, its a hard pass. No need to waste time with that. Think Uber, and other tech-bro places.
If the place is passive aggressive hostile, there are strategies to cope, but again, biased towards pass. Passive aggressive hostility wears on you.
If the place is open, and sane. Worth a look.
Think about the economic aspect of this. You the enlightened consumer/producer of product (grad school, job) have more information than ever about the quality of life at these places. If a place is just bad, they will lose at attracting sufficient consumers/producers of producers. Which means they will have lower ability to operate in market.
Bigger picture. Women are not intrinsically less able to do quantitative or analytical work. Environments that are not conducive to them doing this work will tend to depress the population of them doing this work. Environments which are freer from these stresses will tend to accumulate population doing this work.
I think it might be simple as that. Its not about ability. Its about environment.