In the lounge of a Caribbean resort hotel late Tuesday evening, a clerk loudly paged a guest who had received an emergency phone call. Fears for the children at home gripped the guest and his wife.

At about the same time, the wife of a Wall Street executive answered the phone in her Manhattan apartment and was startled by a voice coolly declaring, "I have an early warning for you."

Those phone calls, and more than 3,000 like them to people in the United States and such European centers as London, Zurich, Geneva, Stuttgart and Frankfurt weren't from cranks or mashers.

They were messages to select clients of the Granville Market Letter, of Holly Hill, Fla., advising them that Joseph Granville, a leading market guru, had decided late Tuesday that the stock market's advance was abruptly ending and that stocks now should be sold. "Sell everything," was Granville's message, relayed to clients by 30 callers working from 6:30 p.m. through 2 a.m. Wednesday.

It was an oracle widely, even blindly, heeded. In Europe, where time differences gave investors a head start, U.S. stocks fell sharply. Brokers there attributed the selling wave entirely to Granville's sudden change of heart.

In the United States, scores of stocks were delayed in opening as word of Granville's switch from raging bull to outright bear circulated early, causing sellers to swamp specialists and brokers.

Jack Kunkel, in the Dean Witter Reynolds office in Milwaukee, was one of many brokers alerting clients about the Granville switch Tuesday night and early Wednesday writing sell orders for many of the clients and for himself and his family. "I wrote over 400 tickets," he says.

Stock prices fell sharply across the board in record trading Wednesday, and nearly everybody was pointing to the Granville advice. The Dow Jones industrial average at one point was down 31 points from Tuesday's close, and it ended the day off 23.80 points at 980.89. New York Stock Exchange volume of 92.89 million shares eclipsed the previous record of 84.297 million shares traded on Nov. 5, 1980.

Brokers said that a cascade of sell orders came from individual investors and from traders but that institutions began pulling back for a better perspective on where the dust would settle. Particularly in the final hour of trading,

"Institutions appeared to become more aggressive on the buy side," says Samuel Hunter, a vice president at Merrill Lynch, Pierce, Fenner & Smith.

Wednesday's overall carnage chopped more than $40 billion from the total value of stocks traded on U. S. stock exchanges and in the over-the-counter market. At year-end, these stocks had a total value of $1.35 trillion.

The advice to sell all stocks, and even to borrow stocks and sell them short, was flashed to clients of Granville's early warning service even while some 10,000 other subscribers of the firm's regular weekly were just opening the latest Granville letter, still grandiosely bullish.

"Do some aggressive new buying," Granville said in his regular letter dated Jan. 3, which specifically recommended General Motors, Cities Service and Getty Oil as well as more than 30 other stocks Granville has been pushing since last April 21.

"The market is signaling a sharp upswing ahead, and most groups look set to respond vigorously." So confident was Granville on Friday, when the letter went to the printers, that he told clients: "The most important thing to know here is that most stocks are set to advance and the probability states that regardless of what you buy right here, it should be higher several weeks from now." Granville titled his letter "Straight Up" and added, "It takes a lot of moxie to use a title like this one."

Moxie is a commodity few have ever accused Granville of lacking, especially in the past several years when his system of technical analysis has brought him a reputation for calling market turns. In often-strident tones, Granville has been openly scornful of other analysts and Wall Street professionals, terming them "bag-holders and losers" in his frequently vaudeville-like appearances before investment audiences.

Granvile boasts that his road show in 1980 involved his traveling 5,000 miles a week by air to address investment audiences. With a flair for showmanship, he delivers his basic message that "the market always tells you where it is going," and that he knows how to read the market's road signs.

On some occasions, he bursts forth on stage holding aloft a large balloon and shouting, "How high is the market going?" and releasing the balloon to the ceiling. He has also been known to provide a song-and-dance routine for his audiences.

Granville hasn't always been so right on the market. After several years of success in selling his own service in the late 1960s, Granville admittedly was on the wrong side of the market at times in the early-to-mid 1970s, something he subsequently attributed to his own neglect of his technical work.

In recent years, however, even though critics have often quarreled with his selection of stocks, (they included losers Chrysler, Bally and Caesars World last year), the analyst has acquired an aura of success and a wide following among individual investors and aggressive traders. This was cemented last April 21, when Granville turned from bearish to bullish on the very day the Dow Jones industrial average ended a decline at 759.13. The average climbed 30.72 points the next day, beginning a sweeping advance in the face of recession and subsequent rising interest rates.

That advance reached a four-year high of 1004.69 on Tuesday. Ironically, it was this latest success of the Dow Jones industrial average that caused Granville to sour on the market, he says.

"We have to be true to our theory," he said in a telephone interview. "When the Dow closed at the new high, a majority of our major indicators failed to confirm that move with their own highs. This is the first time we've had a Dow high that wasn't confirmed by the broader indexes and by other indicators [of volume, new highs and the like] that we follow."

But some other analysts have been warning about this divergence between the blue chip Dow Jones average and other market indicators for several weeks, contending that this left the market vulnerable. Why did Granville wait to turn bearish, and why on the heels of a bullish letter to his regular subscribers?

"When we wrote the letter the Dow closed [Friday] at 963.99, and we wrote that another 50 points up was a piece of cake," he says. "Well, the intraday high yesterday [Tuesday] was 1013.13, and you can't call them any better than that. But the market also left absolutely no doubt Tuesday that it was giving us a sell signal."

What about the subscribers who don't get the early warning? "A lot of people don't understand that our buy and sell recommendations, not forecasts, are the basis of our record," he replies. "We say right out in a legend printed on our letters that all opinions are subject to change without notice. We have to be true to our theory."

But isn't a sell or buy signal from such a widely followed analyst bound to be self-fulfilling, and how useful is sell advice if offerings of stock are so heavy, as they were Wednesday, that few sellers get top dollar on their trades.

"With a growing following, some degree of self-fulfilling prophecy is inescapable," he says. As for timely action on his recommendations, he says, "The market's a fair game and wouldn't give a valid sell signal unless it has the intention of a major new downtrend. Even if sellers are hung up or get bad execution [of sell orders], the odds are that the market will be going down far enough that it pays to act on the recommendation."

Granville says he doesn't know how far down the market will go. But he is delighted with Wednesday's market action. "It looks like we've done it again," he said exuberantly. "When we call a top right to the day, it's a hole-in-one, an ace."

Others managing money in Wednesday's market were understandably less cheered by the market action. "I would have bet a lot of money stocks would have opened higher, and they would have, except for Granville," said one trader. "A lot of people who loaded up with stocks on Tuesday would rather they'd never heard of him."