Lol, it can be safer to take the lane for a short time. If I am on the edge of the road, many people will pass in the lane, not giving me enough room and possibly run me off the road. This being said, I try to plan my route to not include busy and dangerous roads.
I used to live in a city with 300k people, if I would ride at 17 mph, I would make all the lights in the downtown area. Some would get mad, but I would make it in the same time, passing them at every light they stopped at. This road was 4 lanes, so not bad like a busy 2 lane 2 way road.