NEW YORK (Reuters) - The S&P 500 closed in positive territory for the year for the first time in 2016, leading a gauge of stocks across major markets to a fifth week of gains, its longest weekly run in more than two years.
The dollar, meanwhile, edged up on Friday but ended the week lower against a basket of major currencies, giving a weekly boost to energy and other commodity prices. The U.S. currency fell for a third consecutive week, most recently weighed by the Federal Reserves' resetting of market expectations on the number of times it will raise rates in 2016.
Oil prices slipped after hitting 2016 peaks.
On Wall Street, the S&P 500 closed above the level where it ended last year for the first time. Healthcare and financial sector stocks were among the leaders, a welcome signal of rotation for stock bulls.
With the fear of a U.S. recession mostly in the rear-view mirror, investors want to add to stock exposure and are buying up the year's worst performers, according to Art Hogan, chief market strategist at Wunderlich Securities in New York.
"You want to see sector rotation into the laggards," he said, noting that the rise to positive territory for the S&P 500 could mean the five-week stocks rally could lose steam.
"What we've seen is enough good news to say we're not going into recession. This is a short-term top in a longer-term bull market."
The Dow Jones industrial average .DJI rose 120.81 points, or 0.69 percent, to 17,602.3, the S&P 500 .SPX gained 8.97 points, or 0.44 percent, to 2,049.56 and the Nasdaq Composite .IXIC added 20.66 points, or 0.43 percent, to 4,795.65.
The CBOE Volatility Index .VIX a measure of the price traders pay for protection against a slide on the S&P 500, closed at its lowest level since mid-August.
MSCI's index of stocks in major developed markets .MIWD00000PUS gained 1.4 percent this week to end a fifth straight positive week, a streak not seen since February 2014. Stocks in emerging markets .MSCIEF jumped 3.2 percent in their third straight weekly advance.
The dollar index .DXY bounced back from a five-month low, rising against most major currencies, as traders covered short bets triggered by the Fed's statement on Wednesday.
The yen gave back 0.2 percent versus the dollar JPY= after hitting its strongest since October 2014 on Thursday. The euro slipped 0.4 percent to $1.127.
On Friday, the European Central Bank's chief economist, Peter Praet, indicated the ECB could further loosen monetary policy.
"It's been a dizzying selloff for the dollar, so it's natural that you're going to get some kind of bounce," said FX Analytics partner David Gilmore in Essex, Connecticut.
A rising dollar in 2015 weighed on the global economy, and its recent decline has helped push up oil and other commodity prices.
U.S. crude prices slipped after trading above $41 a barrel for the first time since early December as the weekly U.S oil rig count rose for the first time since December. U.S. crude CLc1 settled up for a fifth straight week.
Brent crude's front-month contract LCOc1 fell 0.2 percent to $41.47 a barrel after touching a 2016 high of $42.54.
The benchmark U.S. Treasury note US10YT=RR rose 7/32 in price to yield 1.8784 percent.
Spot gold XAU= closed the week up 0.5 percent after earlier gaining as much as 1.8 percent from last Friday.
Copper CMCU3 posted its highest weekly closing level since October.
Reporting by Rodrigo Campos, additional reporting by Dion Rabouin, Gertrude Chavez-Dreyfuss, Barani Krishnan and Laila Kearney; Editing by Dan Grebler