A day of broad swings in the stock market ended with modest gains Tuesday as investors balanced strong U.S. retail sales with Europe's lingering debt crisis. The Dow Jones industrial average gained 17 points.
The Dow ping-ponged between gains and losses for much of the day. It had been down as many as 78 at noon and up as much as 86 points during a late afternoon rally that fizzled just before the market closed. Technology stocks had the biggest gains.
The Dow Jones industrial average rose 17.18, or 0.1 percent, to 12,096.16.
The S&P 500 index rose 6.02, or 0.5 percent, to 1,257.81.
The Nasdaq composite rose 28.98, or 1.1 percent, to 2,686.20.
For the week:
The Dow is down 57.52, or 0.5 percent.
The S&P 500 is down 6.04, or 0.5 percent.
The Nasdaq is up 7.45, or 0.3 percent.
For the year to date:
The Dow is up 518.65, or 4.5 percent.
The S&P 500 is up 0.2, or less than 0.1 percent.
The Nasdaq is up 33.33, or 1.3 percent.