Hi everyone!
I'm new to the forum. But I felt I have to respond to the question of a woman living abroad in Spain, since I lived there as an American expat for several years.
Madrid... and Spain in general... I think is a much safer place to live than in most places in the U.S. In Madrid, a woman could walk most streets at night with no fear. I know many women living in Spain who would agree.
Spanish culture is very different I think... violence is much less common than the other areas you mentioned. I felt much safer there, than I do in New York, DC, St. Louis, Chicago, or San Francisco.
My 2 euros worth.