(AP) -- Major stock indexes ended a wobbly day of trading on Wall Street mostly lower Tuesday, as losses in energy companies and department store operators edged out gains elsewhere in the market.
A solid showing for technology sector stocks helped lift the Nasdaq composite to another all-time high, while the S&P 500 index finished less than 2 points below the record close it reached on Monday.
Energy sector stocks took the heaviest losses as the price of U.S. crude oil dropped 3.2%. Disappointing earnings from Kohl's sent other retailer stocks into a skid. A slide in Home Depot's stock weighed on the Dow Jones Industrial Average, which ended lower a day after inching to a record high.
"It's almost a carbon copy of yesterday," Jeff Zipper, managing director at U.S. Bank Private Wealth Management. "The S&P basically flat, the Nasdaq obviously up. Right now, the markets, as we go toward year end, their path of least resistance is up."
The S&P 500 index slipped 1.85 points, or less than 0.1%, to 3,120.18. The Dow fell 102.20 points, or 0.4%, to 27,934.02. The Nasdaq climbed 20.72 points, or 0.2%, to 8,570.66.
Smaller company stocks fared better than the rest of the market, driving up the Russell 2000 index up 5.95 points, or 0.4%, at 1,598.29.
Major stock indexes in Europe closed mostly higher.
Bond prices rose, sending bond yields lower. The yield on the 10-year Treasury fell to 1.79% from 1.80% late Monday.
U.S. stocks have been steadily rising for weeks as a mix of solid economic data and corporate earnings inject confidence into the market and diminished fears that a recession was imminent.
Technology, by far the best-performing sector this year, has done especially well as investors have grown more hopeful that the U.S. and China will make progress in ending their trade war. Traders hope the world's two biggest economies can deliver on plans for a "phase one" deal before new and more damaging tariffs take effect next month.
Tech stocks were among the big gainers Tuesday, led by chipmakers. Advanced Micro Devices climbed 3.5% and Broadcom rose 2.1%.
Health care stocks accounted for the biggest swath of gains. Pfizer rose 1.2% and Amgen gained 1.7%.
Those gains were kept in check by losses elsewhere in the market.
Oil producers declined as crude oil prices took another stumble. Marathon Petroleum slid 3.4% and Occidental Petroleum lost 3%.
Energy, which trails all other S&P 500 sectors with a gain of only 1% for the year, dropped 1.5% Tuesday.
Disappointing quarterly report cards from Home Depot and Kohl's weighed on retail stocks.
Home Depot dropped 5.4% after the home improvement company reported weak sales growth for the most recent quarter and cut its forecast for the year. Rival Lowe's, which will report earnings on Wednesday, fell 1.4%.
Kohl's plunged 19.5% after the department store operator slashed its profit forecast for the year following weak third-quarter earnings. The weak outlook prompted traders to dump other department store stocks. Macy's sank 10.9% and Nordstrom lost 6.3%. Both report their own results on Thursday.
Not all big retailers had a bad day. Shares in the TJX Cos., rose 1.8% after the parent of T.J. Maxx and Marshalls reported encouraging third-quarter earnings and raised its profit forecast for the year.
Benchmark crude oil fell $1.84 to settle at $55.21 a barrel. Brent crude oil, the international standard, dropped $1.53 to close at $60.91 a barrel. Wholesale gasoline fell 2 cents to $1.60 per gallon. Heating oil declined 4 cents to $1.86 per gallon. Natural gas fell 6 cents to $2.51 per 1,000 cubic feet.
Gold rose $2.40 to $1,473.30 per ounce, silver rose 11 cents to $17.10 per ounce and copper rose 3 cents to $2.65 per pound.
The dollar fell to 108.53 Japanese yen from 108.65 yen on Monday. The euro strengthened to $1.1078 from $1.1076.