okay so first of all your friend was obviously being disingenuous by saying 'crime' when she meant 'rape' (or SA) because how would what you drink or wear have any impact on whether you were the victim of identity fraud, burglary, car theft, etc.?
But if you want a logical rebuttal to your 'locked house' comparison, it would be if, say, 5% of burglaries occurred when a house was unlocked. So okay, yes, taking precautions like locking your house might make you slightly less likely to become a victim of those type of burglaries. So perhaps not getting drunk to excess or walking home alone (I think the clothing issue is a bit of a red herring) could be a sensible precaution to lower your chances of being a victim of that specific type of crime (rape or sexual assault by a stranger)
The problem with that line of arguing is that
a) It doesn't do anything to lower your chances of being a victim of the far more prevalent type of crime (if the majority of burglaries were break-ins to locked houses i.e. the majority of crime to women INCLUDING SA/RAPE has no link to what they were wearing/drinking/doing)
b) It blames the victim rather than the perpetrator and implies people 'deserve' to be victims - even if your friend accidentally left her house unlocked would you say 'Ah well you deserved it' or 'Shit that's awful I'm so sorry?'
c) It focusses on stopping you as an individual being a victim rather than stopping the crime, full stop. An 'I'm all right Jack' mentality. So if everyone locked their homes a burglar wouldn't just say 'ah fair play, they've outwitted me, time for me to get off down the job centre.' They'd just break into more locked homes. In the same way a rapist wouldn't just not rape if all women were fully covered head to toe in a burqa and never left the house at night, (and would that even be a way you would want to live?) they would just either move onto women who couldn't protect themselves (the homeless, very young, or those with mental health problems) or move to the other type of rape/SA (their friends, family, children, etc.)
tl;dr - your friend's a twat.