Wall Street closed out a dismal third quarter with a mixed performance Thursday after Merck said it would be forced to remove its best-selling Vioxx arthritis drug from the market. Merck's unexpected bad news left blue chips with a loss for the day, while high-tech stocks got a lift from bargain hunters.

Merck's troubles -- Vioxx was found to carry an increased risk of heart attack and stroke -- were magnified because the company is part of the Dow Jones industrials. Analysts said the Dow likely would have been flat to slightly higher without Merck's announcement.

Bad economic news also weighed on stocks as the Labor Department reported the highest increase in weekly first-time jobless claims in seven months, and the Commerce Department reported consumer spending was flat for August.

The Dow fell 55.97, or 0.6 percent, to 10,080.27. The Standard & Poor's 500-stock index slipped 0.22, or 0.02 percent, to 1114.58, and the Nasdaq composite index gained 2.90, or 0.2 percent, to 1896.84.

The major benchmarks ended the quarter substantially lower, with the Dow losing 3.4 percent, the Nasdaq tumbling 7.4 percent and the S&P 500 dropping 2.3 percent.

Merck plummeted 27 percent, or $12.07, to $33, stripping the company of more than $26 billion in market capitalization. Fellow Dow component Pfizer, maker of the rival Celebrex drug, gained 42 cents, to $30.60, while other major pharmaceutical companies were slightly lower. GlaxoSmithKline PLC slipped 11 cents, to $43.73, while Bristol-Myers Squibb fell 19 cents, to $23.67.

PepsiCo rose 55 cents, to $48.65, after it said a growing international business led to a 6 percent rise in revenue for the third quarter. The soft drink company beat Wall Street forecasts by a penny per share.

Nortel Networks said 1,400 jobs would be lost in the United States as the company trims its research and administrative staffs in a cost-cutting measure. The company will take a $450 million charge for the restructuring. Nortel fell 11 cents, to $3.40.

Other Indicators

* The New York Stock Exchange composite index rose 9.57, to 6570.25; the American Stock Exchange index rose 7.45, to 1271.83; and the Russell 2000 index of smaller-company stocks rose 1.87, to 572.94.

* Advancing issues outnumbered declining ones by 3 to 2 on the NYSE, where trading volume rose to 1.75 billion shares, from 1.4 billion on Wednesday. On the Nasdaq Stock Market, advancers outnumbered decliners by 4 to 3 and volume totaled 1.62 billion, down from 1.63 billion.

* The price of the Treasury's 10-year note fell $2.19 per $1,000 invested, and its yield rose to 4.12 percent, from 4.09 percent on Wednesday.

* The dollar fell against the Japanese yen and the euro. In late New York trading, a dollar bought 109.93 yen, down from 110.82 late Wednesday, and a euro bought $1.2433, up from $1.2327.

* Light, sweet crude oil for November delivery settled at $49.64, up 13 cents, on the New York Mercantile Exchange.

* Gold for current delivery rose to $418.70 a troy ounce, from $413.00 on Wednesday, on the New York Mercantile Exchange's Commodity Exchange.