U.S. stocks barely budged on Thursday as investors looked past disappointing jobless claims while a jump in Marathon Oil's shares boosted the oil sector.

Shares of Merck, however, weighed on the market after disappointing drug news pulled the Dow and S&P 500 lower.

Weekly initial claims for unemployment benefits rose the most in six months, the Labor Department said, suggesting the jobs market still faces headwinds. The news caused an initial decline in the stocks, but the market erased most losses by midday.

We're still in the middle of a bull market, said Angel Mata, managing director of listed equity trading at Stifel Nicolaus Capital Markets in Baltimore.

Investors are willing to ignore the jobless number, they are willing to ignore a lot of it, with hope that this is a turning point in the economy.

In one potentially encouraging sign continuing claims retreated sharply to 3.88 million from 4.13 million. Producer prices rose more than expected in December as energy and food costs surged, but underlying inflation remained subdued.

Shares of Marathon Oil Corp gained 7.6 percent to $43.63 after it said it would spin off its refinery and pipeline operations into a stand-alone company.

Marathon was the biggest gainer on the benchmark S&P index and the NYSE ARCA Oil index <.XOI>, which rose 0.7 percent.

The investors have valued oil and gas exploration and production more highly in independent companies than in integrated companies, so the idea that Marathon would recognize that ... does highlight the value in the big companies, said Kurt Wulff, president at McDep LLC in Needham, Massachusetts.

The Dow Jones industrial average <.DJI> edged down 19.60 points, or 0.17 percent, to 11,735.84. The Standard & Poor's 500 Index <.SPX> fell 0.23 point, or 0.02 percent, to 1,285.73. The Nasdaq Composite Index <.IXIC> rose 2.53 points, or 0.09 percent, to 2,739.86.

Merck & Co fell 6.7 percent to $34.65 after it said it would pull a blood clot drug from one study and not give it to some patients in a late-stage trial.

Merck's drop took a toll, driving the S&P Health Care index <.GSPA> down 0.7 percent and the ARCA Pharmaceutical index <.DRG> down 0.8 percent.

Traders were focused on the next major company due to report earnings, chipmaker Intel Corp , whose results were expected after the market closes. Its shares dipped 0.2 percent to $21.26.

JPMorgan Chase & Co , which has recently been leading gains in the banking sector, nudged 0.2 percent higher to $44.80 before its results due on Friday.

Spain and Italy followed Portugal with successful debt sales on Thursday, and investors showed growing confidence that governments would agree to new measures to stem the debt crisis.

(Reporting by Alina Selyukh; Editing by Kenneth Barry)