Stocks rallied most of the day Friday, but fizzled in late afternoon, closing with losses for the ninth day, despite a strong jobs report for October. Investors continue to focus on the U.S. presidential election.

ON WALL STREET: The Dow Jones industrial average gave up 42.4 points, about 0.1 percent, 17,888.3. The Standard & Poor’s 500 index lost 3.5 points, about 0.2 percent, to 2,085.2, and the Nasdaq composite gave up 12 points, about 0.2 percent, to 5,046.4.

OIL PRICES: As markets closed benchmark U.S. crude oil lost 54 cents to $44.71 a barrel in trading on the New York Mercantile Exchange. In London, the price of Brent crude, the international standard, declined 82 cents to $45.53 a barrel.

PRESIDENTIAL RACE: With five days left until the election, Hillary Clinton is still leading in national polling but Donald Trump appears to have narrowed the gap, particularly in swing states. Investors like certainty, and Clinton is seen as likely to maintain the status quo. Trump’s policies are less clear, and the uncertainty has caused jitters in financial markets. Wall Street’s proxy for Trump’s chances at winning, the Mexican peso, was stable most of the day at 19.24 to the dollar.

ANALYST’S TAKE: “No one really knows what Trump would do should he get into power, probably not even himself,” said Joshua Mahony, market analyst at IG. “It is that uncertainty that is driving the market negativity that has dominated this week.”

JOBS BACKDROP: Investors found some solace in data that showed U.S. employers added 161,000 jobs in October and raised pay sharply for many workers. The U.S. Labor Department’s monthly employment report Friday sketched a picture of a resilient job market. The pace of hiring has been consistent with a decent economy. The unemployment rate fell to 4.9 percent from 5 percent. And average hourly pay took a big step up, rising 10 cents an hour to an average of $25.92. That is 2.8 percent higher than a year ago and is the sharpest 12-month rise in seven years.

“This is really good for the U.S. consumer, especially as we head into the critical holiday shopping season,” Michael Scanlon, a portfolio manager at Manulife Asset Management.

advertisement | advertise on newsday

With the election coming up in less than a week, the October jobs report is likely to give the Federal Reserve enough ammunition to raise interest rates at its December meeting, economists said. Fed policymakers ended a two-day meeting on Wednesday, announcing they would hold rates steady this month.

“It seems that the only remaining obstacle to the Fed hiking in December would be a significant adverse financial market reaction to the U.S. presidential election,” analyst Chris Williamson, chief business economist at IHS Markit, wrote in an email.