US stocks cut losses to keep on course for third weekly gain

by