NEW YORK - Wall Street withstood another stream of bad economic readings yesterday, closing sharply higher after investors shuttled between pessimism about the recession and hopes that the nation might start seeing relief soon.

The major indexes saw big swings throughout the day, but all closed up more than 2 percent, giving the stock market its second straight advance.

The day's downbeat news included a drop in productivity, a pullback in the services sector, and the Federal Reserve's finding of worsening economic conditions across the country. Investors were initially disheartened by each piece of news, but they soon shook off their disappointment - until the next dismal report was issued.

Analysts largely say they believe that much of the bad news is already priced into the market, and they again said stocks remained in a bottoming process after the huge declines of the last three months.

"The market is beginning to look forward, and a lot of the selling pressure appears to be abating," said Peter Cardillo, chief market economist at New York brokerage house Avalon Partners Inc. "Perhaps some of the hedge funds are becoming less aggressive in selling, and investors are starting to look at the future."

The market, which also fluctuated sharply Tuesday before closing higher, has now advanced in seven of the last eight sessions. The winning streak was broken only by Monday's big decline that took the Dow Jones industrials down nearly 680 points; even with that plunge, the blue chips have an advance of nearly 1,040 over the eight-session stretch.

Still, stocks are expected to see more volatility as the week progresses, especially with figures for November's retail sales being released today and the government's employment report due tomorrow. Wall Street has been locked for months in a pattern of surging higher only to fall sharply on negative news about the economy and the financial-services sector.

The Dow yesterday rose 172.60, or 2.05 percent, to 8,591.69. The blue-chip index has gained more than 442 points in the last two days, wiping out more than half of Monday's slide.

Broader indexes also closed higher. The Standard & Poor's 500 index rose 21.93, or 2.58 percent, to 870.74, while the Nasdaq composite index rose 42.58, or 2.94 percent, to 1,492.38.

Advancing issues outnumbered decliners by a ratio of about 3-2 on the New York Stock Exchange, where volume came to 1.3 billion shares.

While the market's recent advances are no doubt encouraging, analysts largely expect the turbulence to continue.

"I think these pops are not fundamentally driven," said Jeff Buetow, senior portfolio manager at Portfolio Management Consultants. "I think it's wishful thinking. I don't see any sustainable up move in the equity markets."