April 22, 2013 at 4:04 PM ET
Stocks ended in positive territory Monday, reversing their earlier declines, as strong gains in materials and energy offset weak housing data.
(Read More: Earnings Results Flashing Warning Sign for Stocks)
Still, the S&P 500 and Nasdaq are on track for their first monthly losses since last October.
"We've had a lot of damage over the last week—we were up and down in violent swings—so the market is trying to find some stability," said Kenny Polcari, director at O'Neil Securities.
The Dow Jones Industrial Average squeezed out a small gain, led by Microsoft, while General Electric lagged.
Most key S&P sectors closed in positive territory, led by energy and materials.
"For the short-term we expect the S&P 500 to be range bound between 1,531 and 1,600," wrote Elliot Spar, market strategist at Stifel Nicolaus. "Narrow but lots of opportunities to be on the right or wrong side of many stocks. Many leading and popular names have broken their 50-day moving averages and trend line support. Those are the ones you should avoid buying on dips and should be selling calls against them on bounces to resistance."
Among earnings, Caterpillar posted earnings and revenue that missed Wall Street expectations and cut its full-year outlook for 2013 to reflect a drop in demand for heavy equipment from its mining customers. Still, shares were higher. And the company's CEO Doug Oberhelman told CNBC that he feels confident about the the economy, adding this is the first time in three years where he's seen a "relative degree of stability around the world."
(Read More: Springtime Swoon in Full Gloom: Poll)
Halliburton rallied after the oilfield services company beat earnings expectations thanks to increased international business that helped trump weakness in the North American market.
As of Friday, a fifth of the S&P 500 had reported, and two-thirds had better-than-expected earnings. However, an unusually high amount — 57 percent — missed their top-line revenue estimates, according to Reuters. (Click Here for Complete Earnings Coverage)
Gold rebounded nearly 2 percent, as buyers swooped in after the previous metal tumbled to a two-year low last week. So far, gold has plunged more than 15 percent this year.
(Read More: Can the Gold Bounce Last?)
Shortly after the market open, Google experienced a "mini flash crash," collapsing 3.6 percent to $775 before recovering in a matter of seconds. Strategists at Birinyi Associates said the blip could have been caused by a "fat finger." No trades were cancelled.
And Apple climbed back to its $400 level after BGC Partners upgraded the iPhone maker to "buy" from "hold," ahead of the company's next product cycle. Apple is scheduled to post earnings on Tuesday after the closing bell.
(Read More: Ahead of Earnings, Suppliers Sour on Apple)
General Electric slumped after JPMorgan downgraded the conglomerate to "neutral" from "overweight," while lowering the price target to $22 from $24, citing profit margins and slower growth for the industrial giant.
On the economic front, existing home sales ticked lower by 0.6 percent in March to a seasonally adjusted annual rate of 4.92 million, according to the National Association of Realtors. Economist polled by Reuters had expected home resales to gain to a 5.01 million-unit rate.
(Read More: Housing's Spring Bloom 'Stuck' Due to Short Supply)
Across the Atlantic, European shares closed narrowly mixed. Italy's President Giorgio Napolitano was elected for a second term over the weekend. Napolitano is expected to work to end the political impasse which has gripped the country since February's inconclusive national elections.
(Read More: For Italy, Maybe Some Order From All the Chaos)
In Asia, the Nikkei 225 closed at its highest level in almost five years, after leaders at last weekend's G-20 meeting refrained from criticizing Japan's aggressive monetary stimulus policies and currency depreciation plan. The yen weakened further against the dollar.
—By CNBC's JeeYeon Park (Follow JeeYeon on Twitter: @JeeYeonParkCNBC)
© 2013 CNBC LLC. All Rights Reserved