Wall Street was poised for a panic today that never occurred.

With stock prices collapsing across Asia and Europe, prices plummeted at the opening of the New York Stock Exchange before staging one of the biggest one-day rallies of the year. By the end of the day, the Dow Jones Industrial Average had climbed 32 points from its low of the day to close up 18.55 points from Friday.

After a brief selling flurry that drove the Dow down nearly 15 points in the first half-hour of trading, U.S. investors changed their minds about Armageddon. At the close the Dow had registered its biggest one-day gain since March 15, when the Dow barometer rose 19.09 points. Moreover, a number of major banks reduced their prime lending rate to 19 percent from 19 1/2 percent, adding further optimism at the stock exchanges. Analysts said today's turnaround was the biggest mood swing they can recall.

"It's possible it was a climactic ending to a bear market," said Leslie Alperstein, director of research at Bache Halsey Stuart Shields Inc., a major brokerage firm.

Others, however, were less sanguine about a stock market that has dropped steadily since early July and has fallen into the doldrums since last April, when the Dow average was 1,024.

Donald I. Trott, chairman of the investment policy committee at the brokerage firm A.G. Becker, foresees a volatile stock market on Tuesday followed by a strong rally. Then, however, he predicts stock prices will decline again.

Trott's firm handles transactions for many European investors, and when the day began at Becker, many of its clients had placed huge orders to sell their U.S. stocks. Many told their brokers to sell at prices well below Friday's closing prices, anticipating a substantial price decline at the opening of trading on the New York Stock Exchange, the world's biggest securities market.

Those investors were saying, in effect, "I want out at any price," Trott said.

The bond market, which was hit with early losses, recovered in late trading, too. Bonds rose between $2.50 and $10 for each $1,000 of face value, dealers said. The recovery in the stock market was a big incentive for the bond market.

Selling was strong during the first hour of trading on the New York Stock Exchange. About 17.5 million shares changed hands, compared with 12.9 million on Friday. But most of the sellers were either foreign investors or individual investors. "It was the medium-to-small investor who said, 'The sky is falling,' " according to Pat Ryan, chief trader at the Washington brokerage firm Johnston, Lemon & Co. Inc.

When the Dow average fell below 810, about 10:30 a.m., however, the big institutional stock buyers -- pension funds, university endowments and insurance companies -- began to buy. The Dow average shook off all its losses by 1:30 p.m., then weakened between 2 and 3 p.m. But in the final hour of trading today, it climbed more than 20 points.

Florida stock prognosticator Joseph Granville--who last January triggered a market panic here when he cabled the 3,000 subscribers to his market letter that they should "sell everything"--made investors in Europe, Asia and the United States jittery last week when he predicted more bad times for stock prices and a "Blue Monday" on the New York Stock Exchange, during which prices would fall by record amounts.

Today's declines abroad were not all attributable to Granville. Many investors in Europe and Asia are afraid President Reagan won't be able to hold down U.S. budget deficits and that heavy U.S. Treasury borrowing will lead to higher interest rates in the United States and abroad. Those higher rates, these investors fear, will plunge the world economy into a serious recession.

When the New York Stock Exchange opened, the gallery was filled with reporters and cameramen, waiting for the panic that never quite materialized.

Even before the opening bell, action on the floor was brisk as brokers handled early orders. But the mood never was frantic.

"There was a selloff, but not a panic. It was too well advertised," one broker said. The predictability of the early decline seemed to have taken some of the edge off. "Everybody knew it was coming. It wasn't exactly a bloodbath type of thing. It went down like everybody expected," said Jeffrey Z. Schwartz, a broker with A. Racz & Co.

Although there were believers in the Granville gospel on the floor, most market analysts discounted his impact here, blaming the initial decline on concern about Reagan's policies and reaction to Europe, where Granville appeared to be more of a factor. Many U.S. investors remember that while Granville was right in January, he was wrong about a March massacre. They will remember he was dead wrong about a Blue Monday in New York today.

Some analysts even credited part of the turnaround to Granville. "A lot of traders said Granville is bull. There is no reason to sell off because of Granville, so let's go in and buy," said Becker's Trott.

The 2.2 percent climb in the Dow average of 30 industrial stocks was equalled by a 2.2 percent gain in the New York Stock Exchange's broader index of all its stock. That index climbed 1.46 to 66.42. On the NYSE, 61.8 million shares of stock changed hands today, compared with 54.39 million on Friday.

On the NYSE, 911 issues rose in price, while 659 declined. In early trading, 20 stocks declined in price for every one that rose.

On the American Stock Exchange, the index was up 9.03 to 285.79.