Wall Street breathed a sigh of relief yesterday as a widely feared stock market disaster failed to materialize.

In fact, the Dow Jones industrial average of 30 major New York Stock Exchange companies closed at 1945.13, up 33.82, although slightly more issues declined than advanced on the Big Board.

Investors had feared a stock market crisis yesterday, largely because a 140-point drop in the Dow on Friday was reminiscent of the sharp Friday plunge that preceded Black Monday's 508-point drop in the Dow last October.

Instead of going into a free fall, the Dow average bounced around yesterday in a 100-point range from 1886 to 1985. Volume was relatively light, approaching 159 million shares.

Stock prices surged just after the 9:30 a.m. opening, only to turn quickly lower before 10 a.m. While stock prices were up most of the rest of day, their "yo-yo" pattern reflected investor confusion and fear about the future, according to market analysts and stockbrokers.

The better-than-expected performance of stocks was credited to the stability of the dollar in foreign exchange trading and to the perception that stock price declines in foreign markets were modest.

"I think the main factor in today's market is confusion," said A.G. Edwards analyst Alfred Goldman. "Market participants just don't know whether to jump in or jump out. The market is not giving off any signal of its short-term direction."

Goldman and others said financial market professionals are eagerly awaiting the release on Friday of November's merchandise trade deficit figures.

"If it is $16 billion or greater, then watch out below," Goldman said.

The financial markets increasingly have focused on the trade figures as a measure of the success of the United States in bringing its chronic trade deficit under control. The presidential commission that studied October's stock market collapse said last week that one of the key events that triggered the market collapse was the announcement in October of unexpectedly high merchandise trade deficit figures.

Bonnie Wachtel of Washington's Wachtel & Co. said the nervousness of individual investors was reflected yesterday in the reaction of one of her customers to a phone call.

"I called one of my clients today, for whom I run a relatively small account, to invite her out to lunch," Wachtel said. "When she picked up the telephone, she said she was terrified to get my call because she thought the market must be down like 600 points if I was calling my small accounts. The small investor doesn't know what to expect."

At the other end of the spectrum, major institutional investors, blamed for heavy computer-directed selling that caused the October collapse, did not drive the market yesterday. Shearson Lehman Bros. Vice President Peter Grennan said the impact of computer-related strategies known as program trading, index arbitrage and portfolio insurance was minimal.

"I think everyone came in today prepared for the worst and hoping for the best," Grennan said. "I think you have to consider this the best."

Grennan said the first positive indication he got was the decision by the New York Stock Exchange to allow major investors who use its automated order system to buy and sell hundreds of stocks at the same time they execute related trades in the futures market.

During the October collapse, the NYSE barred investors from using the automated system for such trading.

Dollar traders were watching the stock market for signals yesterday, according to Scott Pardee, vice chairman of Yamaichi International (America) Inc.

Pardee said the dollar traded in a very narrow range throughout the day, adding that traders were anxiously awaiting the Friday trade figures.

He said late Monday trading was at 128.30 yen to the dollar, "up slightly from when I came in this morning."

Pardee said bond prices staged a modest rally late in the day after "oil prices cracked." Oil prices fell 56 cents a barrel on the New York Mercantile Exchange amid reports that oil nations were offering discounts.

On the NYSE, 752 stocks advanced, 852 declined and 379 were unchanged. The broad-based New York composite index closed up 1.78, at 138.81.

The closely watched March Standard & Poor's 500 futures index moved up 6.95, to 247.70, closing at a slight premium to the Standard & Poor's 500 cash index.

The American Stock Exchange index lost 0.48 to 265.96, with the average price per share falling 3 cents.

The Nasdaq compositive index fell 2.27 to 336.20.