The stock market eked out a gain Friday as investors took downbeat economic news in stride. The modest gains still left stocks with a loss for the week, but the Dow Jones industrial average and the Standard & Poor's 500 index logged their best month since November.
The Dow rose 4.23 points, or less than 0.1 percent, to 10,325.26. The S&P rose 1.56, or 0.1 percent, to 1,104.49. The Nasdaq composite index rose 4.04, or 0.2 percent, to 2,238.26.
The latest bad news came from several corners. Insurer American International Group Inc. reported a larger-than-expected fourth-quarter loss. And the National Association of Realtors said sales of previously occupied homes dropped for a second straight month. Analysts had predicted a gain.
The mixed reports added to investors' confusion about the economy. Analysts are divided over whether a recovery is on track.
"We're in a time period where the range of potential outcomes is probably wider than it's been for some time," said Colleen Supran, a portfolio manager at Bingham, Osborn & Scarborough in San Francisco.