I would never say that it would was your fault that you got jumped, just like I would never say a rape victim asked for it. I would say that locking the doors or all the other little habits that fall under tactical thinking reduce the likelyhood of a successful ambush. I would say that knowing the crime stats of the area can be helpful, or varying your routes when traveling creates some randomness that make you hard to pin down if someone is scouting you (doesn't sound like it in this case).
I got jumped on my way to visit a friend at college years back. I was in the country, in an area I knew well and stopped out of the blue at a convenience store that didn't have a high crime history. I 'fell asleep at the wheel' though because of where I parked in relation to the building when there were smarter places to choose. I didn't help myself because I wasn't paying attention as well as I could have been. I didn't at least register the fact that the two guys were lounging around the place when I went in - that would have helped with the police report for description and ID at the very least.
By weapons I mean anything that you can use quickly in a given situation. Your body/mind is the most accessible and after that it depends on what you have that extends beyond that: guns, rocks, bottles, knives... I meant weapons in the theoretical/conceptual definition.
Like you, I didn't cause the attack, but, at 19 years old, 130 lbs and 5'4" I also didn't do the little things that would have made me a less appealing target. Luckily, I got away with only some bruises and a good scare, but I remember in the moment that I had no interest in 'fighting' them. I had all the passion in the world for getting away very quickly.
The other stuff about lifestyle choices is part of what I think to be the bigger picture of martial arts training: Knowing yourself inside and out honestly and with no illusions. If you - meaning a hypothetical you - were a drug abusing, broke prostitute living in a high crime area then obviously the set up is going to lead to a lot of bad things coming your way. Choices, lifestyle and a healthy mental state can greatly reduce the 'random' violence that people might experience.
If we had total control, I would have won the lottery by now.
Paul Martin