The lane is for moving traffic. I would ride in the lane. If a vehicle approached from the rear I would move to the shoulder if I was in a no passing zone or there was on coming traffic. Otherwise I would let it pass me as if i was a car. I would also only ride the shoulder if it was a surface compatible with the bike I was riding. Shoulders have many hidden road hazards. Glass being the biggest one. I ride the right tire track. the tire tracks are keep clean by traffic. Your chance of a tire problem is greater riding out of the track.