It depends on the state (and the kind of road you're on too). Here in SC, a motorized bicycle is considered a moped. It has to be 50cc or less, have a top speed of 30, and it's required to have a mirror, headlight, tail light, and a brake light that operates when you apply the brakes. You apparently do not require a "moped" tag if it has pedals. Those tags are for scooters without pedals. Anyway, I find that if I ride along the white line, even with the lights on, that motorists will get as close to you as possible. There is a 3' law here for bicycles, but most people don't obey it. Riding on the sidewalk is illegal, even without a motor. Even bike trails (which this area is riddled with) do not allow motor vehicles of any sort.
Around here, your options are to ride on the sidewalk and get a ticket (which happens), ride along the white line and have regular near-death experiences, or ride in the middle and hold up some traffic. It forces people to actually change lanes to go around you, and I'm fine with that.
I'll also say that in the Charleston area, mopeds are very common, so people are used to them. You can ride them on a suspended license for 6 months, and you also can not get a DUI on one (somehow). They're referred to as"liquor-cycles". This makes it very desirable to ride one to some. I don't feel bad for holding up traffic. It's perfectly legal to ride, it's my damn right to do so, and if I inconvenience someone by having to put their turn signal on and move their steering wheel 1", then they shouldn't be driving anyway.
And no, I don't ride drunk. I wear a helmet, gloves, jacket, and boots, which is the same gear I wear on my motorcycle.