Traders work on the floor of the New York Stock Exchange, Sept. 17, 2015. Reuters/Brendan McDermid

By Caroline Valetkevitch

NEW YORK (Reuters) -- U.S. stocks ended down slightly on Wednesday, led by losses in materials and energy shares as weak Chinese and U.S. factory data added to growth worries.

Trading was choppy once gain, with the S&P 500 briefly trading higher following afternoon comments by Chinese President Xi Jinping that his country was capable of maintaining a relatively high growth rate for a long time.

The S&P 500 is down 2.8 percent since Thursday, when the Federal Reserve decided to hold interest rates near zero.

Data showed U.S. manufacturing growth stayed at a two-year low in September, while Chinese factory activity shrank to a 6-1/2 year low in the month, underscoring worries about demand.

Boeing Co said it had won orders and commitments from China for aircraft valued at about $38 billion at list prices. But its shares fell 1.7 percent to $131.67.

The S&P materials index, down 2.1 percent, led the decline for the S&P 500 for a second day, followed by the energy index, which was down 1.4 percent.

U.S. crude oil futures ended down 4.1 percent, while shares of Chevron were down 1.5 percent at $76.12.

"The market looks tired and flat, and there is some hesitation to commit with earnings coming out in two weeks and worries about China and the impact on companies that do a lot of business overseas," said Daniel Morgan, senior portfolio manager at Synovus Trust Company in Atlanta.

The Dow Jones industrial average fell 50.58 points, or 0.31 percent, to 16,279.89, the S&P 500 lost 3.98 points, or 0.2 percent, to 1,938.76 and the Nasdaq Composite dropped 3.98 points, or 0.08 percent, to 4,752.74.

Worries over a China-led global economic slowdown and uncertainty over when the Fed may raise rates have left investors skittish.

S&P 500 earnings are projected to decline 3.9 percent in the third quarter from a year ago, Thomson Reuters data showed.

Volume was light due to the Yom Kippur holiday. About 5.9 billion shares changed hands on U.S. exchanges, below the roughly 8 billion daily average for the past 20 trading days, according to Thomson Reuters data.

First Niagara Financial was up 14.5 percent at $10.26 after Bloomberg reported the regional bank was exploring a sale.

Declining issues outnumbered advancing ones on the NYSE by 1,784 to 1,242, for a 1.44-to-1 ratio on the downside; on the Nasdaq, 1,609 issues fell and 1,185 advanced for a 1.36-to-1 ratio favoring decliners.

The S&P 500 posted 1 new 52-week high and 38 lows; the Nasdaq recorded 24 new highs and 135 lows.

(Editing by Nick Zieminski)