Wall Street held at a near standstill on Thursday, with indexes split as caution about rising coronavirus infections in hotspots around the world washed over hopes for a coming economic recovery.

The S&P 500 edged up by 0.1% after flip-flopping repeatedly between small gains and losses through the day. Earlier, stocks slipped in European and Asian markets, while Treasury yields faded in another sign of increased caution.

Slightly more stocks fell in the S&P 500 than rose, but the index ended up adding 1.85 points to close at 3,115.34. The Dow Jones Industrial Average slipped 39.51, or 0.2%, to 26.080.10, and the Nasdaq composite rose 32.52, or 0.3%, to 9,943.05.

Markets worldwide have been showing more apprehension following a tremendous rally for U.S. stocks that began in late March and reached nearly 45% at one point. Surprisingly strong reports on U.S. retail sales and employment have built hopes recently that the economy can pull out of its recession relatively quickly as governments ease up on lockdown orders.

But discouraging numbers on the coronavirus in various U.S. states and elsewhere in the world have dented the optimism. Even if authorities don’t reimpose widespread lockdowns to slow the spread of the virus, the fear is that consumers and businesses could get frightened and pull back on spending. That would damage the fragile improvements that the economy seems to be developing.

“The question and the challenge for those of us who are watching the virus is what will it do to corporate earnings, and will localized shutdowns make the economic recovery even slower than it already is?” said Rob Haworth, senior investment strategist at U.S. Bank Wealth Management. “We’ve had a good snap back, but it still leaves us short of where we were before.”

A report on Thursday showed that the number of U.S. workers filling for unemployment benefits eased for the 11th straight week, down to 1.5 million from nearly 1.6 million. Economists, though, had been expecting a larger decline.

The number of workers who continue to get unemployment benefits also fell slightly. That’s an indication that some employers have begun hiring workers again. But there, too, the improvement wasn’t as healthy as economists had forecast.

“It seemed like the worst was kind of behind us,” said Keith Buchanan, senior portfolio manager at Globalt. “At the same time, in the background, is this pathogen that doesn’t read anyone’s Twitter feed, doesn’t read economic data and doesn’t know optimism or pessimism.”

“The volatility is the market just trying to digest it all,” he said.

One source of support seems to remain constant for markets, though: tremendous aid from central banks. The Bank of England on Thursday increased the size of its bond-buying program to keep interest rates low.

A day earlier, the chair of the Federal Reserve said it will continue to keep interest rates pinned at nearly zero, as well as purchase bonds in far-ranging corners of the market to support the economy. Huge, unprecedented programs by the Fed and Congress in late March were what helped the S&P 500 halt its plunge of nearly 34% when recession worries were at their height.

The S&P 500 has since shaved that loss to 8%, with recent leadership often coming from companies that would benefit most from a reopening economy.

Such stocks bounced up and down with the overall market Thursday. Cruise operator Carnival fell to an early loss of 6.8% after it reported a net loss of $4.4 billion for its latest quarter. But it later recovered and briefly turned positive before finishing the day 1.4% lower.

Stocks of smaller stocks have also tracked with investors’ expectations for the economy, and they likewise swung up and down Thursday. The Russell 2000 index of small-cap stocks ended the day virtually unchanged, up just 0.54 points to 1,427.08, after earlier bouncing between a gain of 0.9% and a loss of 1%.

In Europe, German’s DAX lost 0.8%, and France’s CAC 40 fell 0.7%. The FTSE 100 in London dropped 0.5%.

In Asia, Japan’s Nikkei 225 slipped 0.4%, South Korea’s Kospi lost 0.4% and the Hang Seng in Hong Kong dipped 0.1%.

The yield on the 10-year Treasury slipped to 0.69% from 0.73% late Wednesday. It tends to move with investors’ expectations for the economy and inflation.

A barrel of U.S. oil for delivery in July rose 2.3% to settle at $38.84. Brent crude, the international standard, rose 2% to settle at $41.51 per barrel.