NEW YORK (AP) -- Treasury yields rose Tuesday, and the Standard & Poor's 500 index slid to its first loss in four days after the head of the Federal Reserve said that he's feeling more optimistic about the economy.
The testimony by Fed Chairman Jerome Powell before Congress was highly anticipated, and he gave encouraging words about the economic data that have arrived in recent weeks. But some investors speculated they could mean the central bank will get more aggressive in raising interest rates than the market has prepared for.
"My personal outlook for the economy has strengthened since December," Powell said in response to a question about whether the recently passed tax cut and other moves by Congress have changed his outlook for how quickly the Fed will raise interest rates.
The immediate reaction in the bond market was to send Treasury yields higher, and the yield on the 10-year note climbed to 2.90 percent from 2.86 percent late Monday. It had been down earlier in the morning.
Higher interest rates can hurt stock prices by making bonds more attractive. Generally, when interest rates are rising, companies need to produce bigger profits just for their stock prices to stay flat.
The S&P 500 fell 35.32 points, or 1.3 percent, to 2,744.28. It had been bouncing between modest gains and losses early in the morning, but the losses accelerated after Powell began answering questions on Capitol Hill.
The Dow Jones industrial average lost 299.24, or 1.2 percent, to 25,410.03, and the Nasdaq composite fell 91.11, or 1.2 percent, to 7,330.35.
The Fed raised its key policy interest rate three times last year and has signaled that another three increases may be coming in 2018. Powell reaffirmed to the House Financial Services Committee that the central bank plans to raise interest rates gradually as the economy improves.
The market got spooked earlier this month when potential signs of inflation strengthened, which raised speculation that the Fed may speed up its timetable. Stocks around the world fell sharply as a result, with the S&P 500 losing 10 percent from its record high at one point.
If the Fed does raise rates four times this year, it could upset markets when many investors have been preparing for only three increases, said Rich Weiss, chief investment officer of multi-asset strategies at American Century Investments.
What may make things even more muddled is how long it's been since investors have had to contend with a market where inflation is a threat and interest rates are rising, Weiss said. The last time was before the 2008 financial crisis.
"You have a generation of brokers and advisers who have not experienced this side of the economic cycle," he said.
The rise in Treasury yields sent stocks that pay big dividends to some of the market's steepest losses. When bonds are paying more in interest, they can lure income investors away from dividend-paying stocks.
Real-estate investment trusts in the S&P 500, which are among the biggest dividend payers, lost 2.1 percent for the biggest loss among the 11 sectors that make up the index. Utilities fell 1.7 percent.
Comcast had one of the biggest losses in the S&P 500 after it launched a bid for European pay TV broadcaster Sky. The buyout offer is for 22.1 billion pounds ($29.5 billion), and Comcast's Class A shares lost $2.92, or 7.4 percent, to $36.66.
Shares of Walt Disney also fell because the Comcast bid could disrupt its takeover offer for 21st Century Fox. Disney lost $4.94, or 4.5 percent, to $104.87.
On the winning end was Macy's, which jumped to one of the biggest gains in the S&P 500 after reporting sales and profits that were comfortably ahead of expectations. The retail giant also gave a forecast for 2018 earnings that was higher than analysts expected.
Macy's rose 95 cents, or 3.5 percent, to $28.40.
In Europe, stock indexes were mixed with France's CAC 40 close to flat and Germany's DAX down 0.3 percent. The FTSE 100 in London was down 0.1 percent.
In Asia, Japan's Nikkei 225 jumped 1.1 percent, South Korea's Kospi dipped 0.1 percent and the Hang Seng in Hong Kong lost 0.7 percent.
In the commodities markets, benchmark U.S. crude fell 90 cents to settle at $63.01 per barrel. Brent crude, the international standard, dropped 87 cents to $66.63 per barrel.
Natural gas was nearly flat at $2.68 per 1,000 cubic feet, heating oil fell 2 cents to $1.96 per gallon and wholesale gasoline lost 2 cents to $1.80 per gallon.
Gold dropped $14.20 to $1,318.60 per ounce, silver lost 19 cents to $16.43 per ounce and copper fell 4 cents to $3.19 per pound.
The dollar rose to 107.42 Japanese yen from 106.91 yen late Monday. The euro dipped to $1.2236 from $1.2312, and the British pound fell to $1.3916 from $1.3968.