President Trump’s announcement of a 25 percent tariff on steel imports triggered a global stock sell-off. (Richard Drew/AP Photo)

U.S. markets recovered most of their early losses on Friday as 2018 keeps up a highly-volatile year on the exchanges.

The Dow Jones industrial average dropped more than 350 points out of the gate, but recovered most of those losses to close down 70 points, less than one-third of a percent, at 24,538.

The Standard & Poor’s 500-stock index finished Friday barely in positive territory. The tech-heavy Nasdaq Composite finished up more than 1 percent.

The Dow was down 3.05 percent on the week — and is now in negative territory for 2018.

Investors across the globe continued to signal anxiety about President’s Trump pledge to impose tariffs on imports — 25 percent on steel and 10 percent on aluminum — and the prospect that it could trigger a global trade war.

“Markets are responding to the very real economic damage to large sectors of the economy that the tariffs will cause,” said Brad McMillan, chief investment officer for Commonwealth Financial Network, which manages $156 billion in assets. “This is a rational response, based on clear economic factors.”

Trump doubled down on his position in a tweet Friday morning: “When a country (USA) is losing many billions of dollars on trade with virtually every country it does business with, trade wars are good, and easy to win.”

Trade wars start when countries initiate protectionist measures such as tariffs and quotas to protect domestic industries from foreign competition. A tariff is essentially a tax on imports, designed to raise their price or limit their ability to sell in the U.S. by setting a quota.

Tariffs can result in higher prices passed to the consumer, spurring inflation. The other risk is that U.S. trading partners will react with their own tariffs and limits, which could injure U.S. domestic producers —  from agriculture to automobiles to technology.

Foreign leaders expressed alarm at the president’s decision. The biggest supplier of steel to the United States is Canada. Its officials said the steel and aluminum tariffs would be unacceptable. Canada “will take responsive measures,” Foreign Minister Chrystia Freeland said.

Alexander Winterstein, a spokesman for the European Commission, told reporters on Friday that “counter measures” would be swift, firm and proportional.

German politician Bernd Lange, who heads the trade committee at the European Parliament, declared: “With this, the declaration of war has arrived.” Lange called Trump’s logic for the tariffs “absurd” and said they “contradicted the reality of global trade relationships.”

Europe’s markets sustained losses, too. Germany’s blue-chip DAX and France’s benchmark index were both down 2 percent. In Asia, Japan’s Nikkei lost 2.5 percent. And Hong Kong’s Hang Seng Index dropped 1.5 percent.

Li Xinchuang, vice secretary general of the China Iron and Steel Association, called the tariffs “an extremely stupid move” and “a desperate attempt by Trump to pander to his voters, which I think in fact runs counter to his ‘America First’ pledge.”

Tariffs have some unhappy history in the United States. The starkest example may be the Smoot-Hawley Tariff signed into law in 1930, which was derided by economists but signed anyway by President Herbert Hoover. Smoot-Hawley raised tariffs on thousands of imports and, by discouraging free trade, is now viewed by many economists as a key contributor to the length and depth of the Great Depression.

Steel and aluminum are such basic commodities that critics fear a tariff could ripple through the U.S. economy, raising prices on vehicles, pipelines, boats, airplanes, locomotives and various industrial instruments. Even beer. Because so many industries could be affected, the stock market reaction has been broad.

The Dow was already reeling from a 380-point decline on Wednesday on fears of continued interest rate hikes by the Federal Reserve. Fed Chair Jerome H. Powell spoke this week before Congress, where he left open the possibility of four rate hikes this year instead of three.

Volatility has returned to markets this year after a relatively calm — yet robust — 2017. The Dow and S&P sank 10 percent into correction territory in early February on a positive Labor Department report on wages that inflamed Wall Street’s fears of inflation and coming rate increases.

When February ended on Wednesday with another seesaw day, the Dow and S&P were down. The negative month broke 10 consecutive months of gains, which is the longest uninterrupted stretch of gains since 1959.

On Friday, Intel, Johnson & Johnson and Merck were among the strongest performers in the Dow on Friday. Boeing, Caterpillar and McDonald’s were the biggest drags. The fast-food maker lost 4.77 percent of its value on one of its worst-performing days ever. Analysts cut same-store sales expectations for the restaurant chain, sending the blue-chip stock down.

Steel and aluminum account for roughly 2 percent of world trade, so the direct impact on the global economy would be muted, according to John Lynch, chief investment strategist at LPL Financial.

Lynch said the U.S. automobile industry will be a loser.

“They are already facing slower sales and rising interest rates as headwinds,” Lynch said.  Despite the noise from tariffs and interest rates, Lynch said he remains bullish on stocks.

He sees the S&P rising to between 2,950 to 3,000 by the end of the year, a 12 percent pull above its present level.

McMillan emphasized that for investors the fundamentals of the economy “remain sound” with steady growth and rising corporate profits.

“There is also the very real possibility — even likelihood, that this is more of a negotiating tactic than a firm policy proposal,” McMillan said.