NEW YORK — U.S. stocks abruptly changed course again Tuesday and took large losses. Investors worried about the possibility of a weaker global economy and tried to anticipate the Federal Reserve’s plans for interest rates. Energy companies fell with the price of oil after a leading industry group said demand for oil is down more than it previously thought.

Stocks sank over the first few hours of trading and never regained their footing.

The Dow Jones industrial average gave up 258.32 points, or 1.4 percent, to 18,066.75. The Standard & Poor’s 500 index fell 32.02 points, or 1.5 percent, to 2,127.02. The Nasdaq composite lost 56.63 points, or 1.1 percent, to 5,155.25.

The price of oil fell 3 percent after the International Energy Agency’s remarks about oil demand. The group expects weaker growth because of a more pronounced slowdown in the global economy.

Apple was one of the few bright spots after T-Mobile said preorders for Apple’s newest iPhones are strong.

After two months of unusual calm on the markets, stocks have whipsawed over the last few days. They plunged Friday and recovered about half those losses on Monday, only to drop lower Tuesday. Confusion over the Fed’s intentions has been a major factor.

Randy Frederick, vice president of trading and derivatives at Charles Schwab, said investors don’t know what the Fed will do at its meeting next Tuesday and Wednesday and the market may remain volatile until then.

“Some of the things they said Friday scared people,” he said. “Monday they tried to calm them down. Now they’re in a quiet period so we don’t know what they’re thinking.”

The IEA, which represents 29 oil-producing countries, is predicting slower growth in demand for oil because of a more pronounced economic slowdown during the third quarter of the year, among other factors. The price of oil has plunged over the last two years as an enormous supply glut built up while growth in demand slowed.

Investors have been worried about a possible slowdown in economic growth. Those fears were a big reason stocks tumbled in January and early February.

U.S. crude fell $1.39, or 3 percent, to $44.90 a barrel in New York.