NEW YORK (Reuters) - Technology shares led the S&P 500 marginally higher on Wednesday, as a healthy forecast from IBM helped mitigate worries over the developing coronavirus outbreak.

The S&P 500 and the Nasdaq closed barely in the black after approaching, then backing down from record highs the day after virus fears prompted a sell-off. The Dow closed nominally lower.

“The market’s had a big run, that’s made some investors a bit skittish, cautious,” said Tim Ghriskey, chief investment strategist at Inverness Counsel in New York. “So we’re not seeing a really strong day.”

“Earnings season is always volatile and unpredictable,” Ghriskey added. “Every new earnings report that gets released is another piece of the puzzle.”

Optimism was boosted by International Business Machines IBM.N, which posted surprise quarterly revenue growth and forecast higher-than-expected full-year profit. Its shares advanced 3.4%.

Chipmakers rose following a strong forecast from Dutch semiconductor equipment maker ASML Holding NV ASML.AS.

The Philadelphia SE Semiconductor index .SOX gained 0.8%.

Global precautions have been put in place to curb a viral outbreak from China, which has now claimed 17 lives. The World Health Organization (WHO) has convened to determine whether the situation was a global health emergency.

The Dow Jones Industrial Average .DJI fell 9.63 points, or 0.03%, to 29,186.41, the S&P 500 .SPX gained 0.98 points, or 0.03%, to 3,321.77 and the Nasdaq Composite .IXIC added 12.96 points, or 0.14%, to 9,383.77.

Traders work on the floor at the New York Stock Exchange (NYSE) in New York, U.S., January 21, 2020. REUTERS/Brendan McDermid

Of the 11 major sectors in the S&P 500, six ended the session in positive territory. Tech .SPLRCT was up the most, while energy .SPNY was the biggest laggard.

Fourth-quarter earnings season is well under way, with 58 companies in the S&P 500 having reported, 67.2% of which have beaten analyst expectations, according to Refinitiv data.

Analysts now expect fourth-quarter earnings to have contracted by 0.8% year-on-year.

Streaming pioneer Netflix Inc NFLX.O acknowledged stiffer competition in the United States, where quarterly growth fell short of analyst estimates. Its shares closed down 3.6%.

Shares of Boeing Co BA.N extended their fall, dropping 1.4% in the wake of the planemaker's announcement that it does not expect approval for its 737 MAX aircraft to return to service until summer.

Tesla Inc TSLA.O continued its rally, rising 4.1% and becoming the first publicly listed U.S. automaker to cross the $100 billion market valuation mark.

On the economic front, sales of existing homes in December blew past economist estimates to reach a near two-year high.

Advancing issues outnumbered declining ones on the NYSE by a 1.10-to-1 ratio; on Nasdaq, a 1.03-to-1 ratio favored decliners.

The S&P 500 posted 109 new 52-week highs and two new lows; the Nasdaq Composite recorded 164 new highs and 29 new lows.

Volume on U.S. exchanges was 7.20 billion shares, compared with the 6.80 billion-share average over the last 20 trading days.