Stocks gave back gains late Wednesday afternoon as the Federal Reserve left interest rates unchanged and Fed Chair Janet Yellen expressed her confidence in the strength of the U.S. economy, despite recent signs of weakness. 

The S&P 500 was down 0.08%, the Dow Jones Industrial Average fell 0.08%, and the Nasdaq slid 0.09%. 

The Fed expects to stick to its plan to gradually increase rates alongside expected growth in the U.S. economy, Yellen said in a speech following a two-day meeting of the Federal Open Market Committee. Yellen cautioned investors not to overreact to one piece of data, such as a weak May jobs report, and reiterated her belief the economy will grow at a moderate pace. Weakness in the first quarter appears to be temporary, Yellen added. 

The average Fed member expects the U.S. economy to grow about 2% with the unemployment rate dipping to 4.6% in 2016. Inflation is expected to increase to the Fed's 2% target rate by the end of 2018. 

The Fed concluded its monetary policy meeting on Wednesday afternoon with no change in monetary policy. Chances of a June rate hike were virtually non-existent heading into the announcement. The central bank kept its fed funds rate outlook unchanged in 2016, though lowered its outlook for 2017 and 2018. Fed members said it still foresees a gradual pace of tightening. Six Fed officials now see just one rate hike this year, up from just one official. 

"Even if two rate increases ultimately are approved in 2016, rates will only be between 75 and 100 basis points at year's end -- still extremely low, but reflective of at least some confidence in the U.S. economy," said Paul Eitelman, investment strategist at Russell Investments. "In any event, we're back on Fed watch; realizing any FOMC decision to raise or not raise rates this year will continue to have an impact on global markets."

Crude oil recovered from lows on Wednesday, though still closed out its fifth straight losing session, after a decline in U.S. inventories over the past week. Crude inventories fell by 900,000 barrels, according to the Energy Information Administration. However, the decline wasn't as steep as an expected drop of 2.7 million.

West Texas Intermediate crude oil fell 1% to $48.01 a barrel by its close on Wednesday. Oil had fallen below $48 earlier in the session.

TheStreet Recommends

Industrial production fell 0.4% in May after a revised 0.6% gain in April, according to the Federal Reserve. The decline was mainly due to a 4.2% drop in motor vehicle production. Weaker manufacturing sector activity dragged production lower. 

Producer prices in the U.S. rose 0.4% in May, above estimates for a 0.3% increase. Core prices, excluding food and energy, fell 0.1%. Producer prices have risen 0.1% over the past 12 months.

Economic conditions in the New York region improved in June after a disappointing read in May. The Empire State index climbed to positive 6 in June from negative 9 in May.

Procter & Gamble (PG) - Get Procter & Gamble Company Report was rated a new buy at Jefferies. The firm said P&G  can return to 3%-plus organic sales growth in the coming years.

Procter & Gamble is a holding in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio. Want to be alerted before Cramer buys or sells PG? Learn more now.

Best Buy (BBY) - Get Best Buy Co., Inc. Report  climbed despite being downgraded to neutral by Credit Suisse. Analysts pointed to worries over slowing sales in the second half of 2016. The firm cut its price target to $31 from $36.50.

Whole Foods Market (WFM) continued its decline on Wednesday, a day after the Food and Drug Administration found "serious violations" at its Massachusetts plant. Regulators found issues with the company's packing and handling of food. Shares have fallen more than 7% over the past two days. 

Aegerion Pharmaceuticals (AEGR) spiked after agreeing to merge with fellow biotech company QLT (QLTI) . Each Aegerion share will be exchanged for 1.0256 QLT shares. The merger is expected to be completed by at least the end of the third quarter and the merged company will be called Novelion Therapeutics.

Twitter (TWTR) - Get Twitter, Inc. Report has invested around $70 million in music service SoundCloud. The latest investment is part of a round that should end up in the $100 million range, Re/code reported, and is expected to value SoundCloud at around $700 million.

Twitteris a holding in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio. Want to be alerted before Cramer buys or sells TWTR? Learn more now.