N.Y. VAT. LAW § 1128 : NY Code - Section 1128: Driving on roadways laned for traffic

Whenever any roadway
  has been divided into two or more clearly marked lanes for  traffic  the
  following  rules  in  addition  to  all others consistent herewith shall
    (a) A vehicle shall be driven as nearly as practicable entirely within
  a single lane and shall not be moved from such lane until the driver has
  first ascertained that such movement can be made with safety.
    (b) Upon a roadway which is divided into three lanes and provides  for
  two-way  movement of traffic a vehicle shall not be driven in the center
  lane except when overtaking and passing another vehicle traveling in the
  same direction when such center lane is clear of traffic within  a  safe
  distance,  or in preparation for making a left turn or where such center
  lane is at the time allocated exclusively to traffic moving in the  same
  direction  that  the  vehicle  is  proceeding  and  such  allocation  is
  designated by official traffic-control devices.
    (c) When official traffic-control devices direct slow-moving  traffic,
  trucks, buses or specified types of vehicles to use a designated lane or
  designate  those  lanes  to  be  used  by traffic moving in a particular
  direction regardless of the center of the roadway, drivers  of  vehicles
  shall obey the directions of every such sign, signal or marking.
    (d)  When  official markings are in place indicating those portions of
  any roadway where crossing such markings would be especially  hazardous,
  no  driver  of a vehicle proceeding along such highway shall at any time
  drive across such markings.