It also makes you appear a little less experienced/skilled/confident and drivers tend to give you more room as they think you're about to fall off. I have no evidence to back it up but I'm convinced I have more room given to me when I'm slogging away in "normal" clothes commuting on the mountain bike than I do when I'm lycra clad on the roadie, having spoken to my wife about it (she doesn't cycle) she has told me that when she is driving her immediate assumption is that the lycra biker must be more experienced than one that isn't dressed as such, even though she knows it isn't the case.
That's interesting. I find I get more close passes on the MTB, which I put down to the fact I'm going slower, and drivers are more likely to squeeze past because their perception of being "held up" is greater. There's one road that I'll happily ride at any time on the road bike, but only at weekends on the MTB because the close passes from lorries on weekdays makes it very unpleasant. I don't get it on the road bike, and I assume that's because they're waiting for a safe place to pass.
I've found not holding a straight line does get you more room. (I discovered it when I was first learning how to drink on the move, and tended to wobble when I was getting the bottle in or out of the cage.) I now use it to my advantage often, and also find positioning the hand holding the bottle out where it's visible if I'm having a drink gets me more room, presumably because I'm perceived as more of a hazard when I've clearly only got one hand on the bars.
One thing that hasn't been mentioned here is female cyclists getting more room. I had my hair cut short last autumn, and immediately noticed the number of close passes increased. I've tried wearing a pink jersey, but that doesn't seem to help because Spanish men don't have issues with wearing pink. I'm now growing my hair again!
To the OP, there are some dangers in cycling on the road, but that can be said of anything in life, including walking along your local high street, or driving to the supermarket. The more often you do it, and the more often your fears are not realised, the more confident you will become. (Unless it's an actual phobia, where repeatedly exposing yourself to the source of your fear may not help - it didn't help me with my phobia. But there are people who can help with phobias.)