I don't think that was the reason (although women do have that mindset in regards to male spaces, which is why they attempt to infiltrate and/or shut them down so often). The reason is economical. Countries with higher numbers of females in STEM correlates with more wealth inequality. Women in those countries have to earn money legitimately and STEM pays well. Unlike the west which subsidizes and babies women with welfare, divorce settlements, affirmative action and shit.
In other words, if the west wants more women in STEM they have to stop enabling women with free handouts and male wealth distribution. Its more or less the same reason why more men take high risk jobs. We have to work because we have no choice and no-one else will support us.