US stocks end lower for 4th day as Dow erases 2023 gains