GettyImages-509763290
Traders work on the floor of the New York Stock Exchange, Feb. 12, 2016. andrew burton/getty images

This story was updated at 4:35 p.m. EST.

U.S. markets closed up Wednesday following mixed performance in global markets and a rise in oil prices after a two-session rally that gained momentum during the Presidents Day holiday.

The Dow touched positive territory for the month before closing slightly down.

Investors looked to U.S. data on housing and industrial production for the latest hints on the direction of the economy.

"It's important to keep it in perspective of what's been going on this year, not to get too lulled by strong up days," Jeff Knight, global head of investment solutions at Columbia Threadneedle Investments told CNBC's "Squawk Box.” "Big up days oftentimes don't signal the all clear."

The Dow Jones Industrial Average (INDEXDJX:.DJI) closed up 257.42 points, or 1.59 percent to 16,452.83. The broader Standard & Poor's 500 index (INDEXSP:.INX) gained 31.24 points, or 1.65 percent, to 1,926.82. The Nasdaq composite (INDEXNASDAQ:.IXIC) rose 98.11 points, or 2.21 percent, to 4,534.06.

Nine out of 10 S&P 500 sectors were up, led by energy and information technology. Only utilities stocks were down, slightly.

Gains among the Dow 30 components were led Wednesday by aerospace giant Boeing Co. (NYSE:BA), Chevron Corporation (NYSE:CVX) and International Business Machines Corp. (NYSE:IBM). Leading Dow declines for the session were fast food leader McDonald's Corp. (NYSE:MCD) and drugmaker Pfizer Inc. (NYSE:PFE).

Official data released Wednesday morning showed an unexpected slowdown in new home construction in January, a signal that residential real estate activity will contribute modestly to first-quarter U.S. economic growth.

Housing starts dropped to an annualized rate of 1.09 million, a 3.8 percent drop and the weakest since October. Analysts polled by Bloomberg expected 1.17 million units. While East Coast economic activity was battered by Winter Storm Jonas, all four U.S. regions saw declines in new-home construction. Housing permits, a measure of future home building, remained unchanged, offering hope that January’s unexpected drop is temporary.

On a more positive note, U.S. industrial output rose 0.9 percent after a downward revision of 0.7 percent growth in December, according to the U.S. Federal Reserve. The data caps three consecutive months of decline and was higher than the 0.4 percent forecast by economists polled by Thomson Reuters.

Minutes from last month’s Federal Reserve meeting were released Wednesday afternoon, providing more insight into the U.S. central bank’s decision to keep short-term interest rates unchanged. The minutes showed that Fed policy makers are concerned about the effects of a global downturn on the U.S. economy. They considered altering their planned rate hikes for the year. If the Fed delays further hikes, it would be considered good for corporate earnings because it keeps borrowing costs down.

Safe Harbor Bets

The benchmark U.S. 10-year Treasury yield dropped to 1.817 percent on Wednesday after gains earlier in the day. Last week, the yield dipped to its lowest level in nearly a year. The bond yield typically rises when investors are more confident about the markets and falls when concerns flare. Gold, another so-called safe harbor investment, edged up 0.03 percent to $1,208.60. Gold prices tend to rise as confidence in the markets falls.

Oil Prices

Oil prices rose ahead of a meeting in which OPEC oil ministers will try to convince Iran to join Russia and Saudi Arabia in freezing further crude export increases. The effort comes as Iran deployed its first shipment of Europe-bound crude since the lifting of most Western sanctions last month.

On Wednesday, U.S. West Texas Intermediate gained 5.61 percent to $30.67 per barrel for March delivery on the New York Mercantile Exchange. Brent crude, the other major global benchmark, gained 6.71 percent to $34.34 for April delivery on the London ICE Futures Exchange.

Global Markets

Asian markets were mostly down Wednesday, despite Wall Street’s positive performance Tuesday.

Japan’s Nikkei 225 ended the day down 1.4 percent after eking out a slight gain earlier in the day. Hong Kong’s Hang Seng also took back early-session gains to close down 1 percent. China’s mainland exchanges benefited from central bank moves Monday to widen the band in which the yuan is traded and inject 10 billion yuan ($1.5 billion) in short-term loans into its banking system. The Shanghai Composite Index closed up 1.1 percent. The smaller Shenzhen Index gained 1.3 percent. The broad Shanghai Shenzhen CSI 300 of the mainland’s largest companies advanced 0.9 percent.

Europe’s main stock exchanges were up for a second session in a row Wednesday, helped by rises in French bank Credit Agricole SA (EPA:ACA) on positive fourth-quarter earnings released Wednesday and Glencore PLC (LON:GLEN), after the British miner announced a refinancing if its debt.

The broad Stoxx Europe 600 index closed up 2.57 percent on Wednesday. The Paris-based CAC 40 gained 2.99 percent while London’s FTSE advanced 2.87 percent. Frankfurt’s DAX rose 2.65 percent.

Market Movers

AstraZeneca plc (LON:AZN) shares rose 2.28 percent after the U.S. Food and Drug Administration granted the British drugmaker a “breakthrough therapy” designation for its bladder cancer treatment durvalumab.

Bloomin' Brands (NASDAQ:BLMN), which owns the Outback Steakhouse restaurant chain, beat adjusted quarterly earnings estimates for the three months ending in December and raised its quarterly dividend. But the company missed on revenue, which sent its share price plunging 10.7 percent.

Campbell Soup Company (NYSE:CPB) stock rose 2.46 percent after the company raised its earnings expectations for 2016, helped by cost cutting measures.

Devon Energy Corp. (NYSE:DVN) shares plunged 4.37 percent after the company reported a miss on revenue for its latest quarter. It’s also cutting a fifth of its staff amid a global oil glut that’s battering energy-sector companies.

Kinder Morgan Inc. (NYSE:KMI) stock jumped 9.86 percent after the pipeline operator announced new investments by Warren Buffett's Berkshire Hathaway.

Priceline Group (NASDAQ:PCLN) shared jumped 11.24 percent after the travel website operator beat revenue estimates for its quarter ending in December.

T-Mobile US Inc. (NASDAQ:TMUS) stock rose 1.1 percent after the mobile services operator reported better-than-expected revenue and profit for the three months ending in December.