Women constantly generalize about men. Here's the thing you, as a guy, have to understand. When women generalize about men, they are almost universally generalizing about specific men or specific groups of men in their experience. They are almost never talking about men taken as a whole.
If a woman says "All men are pigs" what she really means is "All men I am attracted to are pigs". This is worth noting, because frankly it's a map providing you a pathway into her life. If you fit the profile of her type of jerk, you're gonna have an in with her.
If a woman says "Where are all the nice guys" what she really means is "I only let in seriously shady and evil motherfuckers".
If a woman says "I don't know why guys won't talk to me", what she really means is "Why don't the guys I wanna fuck talk to me?" There's a specific girl I have in mind when I say this. She goes out nearly every night. She has an army of potential suitors. And she gets hit on several times a night every night!
So, what's going on there?
Well, for one, she's an attention whore. I called her out on this the first time she hit on me. She's been tied in knots chasing me ever since.
Two, she's dialed in pretty much on one guy. Me. And it's pissing her off. Worse, I've arrived at the conclusion she's too immature for me. But, I'm immature and enough of an attention whore myself that I keep giving her a glimmer of hope.
Understand, when women generalize about men they're actually skirting the embarrassment of admitting specific failures in their dating lives. No one wants to admit they're only attracted to assholes. This is where dumbass, meaningless phrases like "bad boy" come from. Women minimize their own faults and failures all the time.
Worse, they badly minimize the faults and failures of the men that turn them on, because they're aware of how poorly it reflects upon them. It's far better to act like all men are assholes than it is to admit you;re not attracted to decent men. It's far easier to think you're gonna find Denzel from Training Day but that he'll act like Denzel from The Preacher's Wife than it is to admit you just like bad guy Denzel.
Also, frankly, it's easier to think that guys are all tentative and afraid to talk to you than it is to admit that the guys you're attracted to just aren't into you.
Women are creatures with fragile egos. They have a gift for diminishing the social and psychological damage of their own actions and of how the world reacts to them. They do this at a speed that astonishes most men. We men, we have to plan this shit like a major PR campaign. For women, it just flows right out almost stream of conscience.
Be aware of these things when you're listening to women. It will surprise you.