US stocks end lower ahead of inflation data