In the days when Ronald Reagan was typecast as a B-movie actor, Hollywood followed a simple casting formula that Reagan never forgot.

The formula, which saved time and creative thought, was to make a sequel of any commercially successful movie, preferably using the same cast. Reagan and many others wound up in some real clunkers that way, including four films in which he played an improbable Secret Service agent named Brass Bancroft.

In real life, Reagan has stuck to the same basic script since he first ran for governor of California in 1966. Aspiring to be a two-term president, he is still running against government and its supposed waste, fraud and abuse. Over the years, his supporting cast has changed from time to time but has always included a trusted and identifiable cadre from Reagan's formative years as governor.

In the absence of specifics from the White House, Reagan's habits of sticking to old scripts and the same team provide the most useful clues to what is likely to happen in a second term.

In the first term, with no one making a point of it, some of the new crowd became a part of the old. Within the White House, chief of staff James A. Baker III and Reagan's closest aide, deputy chief of staff Michael K. Deaver, formed a firm alliance that ultimately disposed of all rivals. By all accounts, Reagan is now comfortable with Baker, who once managed the presidential campaigns of Gerald R. Ford and George Bush, and with most of the people Baker has brought on board.

There are right-wingers organizing against Baker, a chief of staff they regard with about as much affection as they do Soviet Foreign Minister Andrei A. Gromyko. Their opposition isn't likely to sway Reagan, who understandably resents the suggestion that he is the captive of a liberal cabal.

By any normal definition, the struggle within the Reagan administration has been between conservatives who differ on process rather than on goals. Reagan recognized as much two years ago, during a period of White House feuding, when he cracked that his administration was one where "the right hand doesn't know what the far-right hand is doing."

Ideology aside, the conventional wisdom in Washington is that Reagan, if reelected, would have a short "window of opportunity" to accomplish something in the honeymoon phase of a second term and a large "window of vulnerability" thereafter. He would be a lame duck at the moment of reelection. His chances for political success would diminish as mid-term elections approached and could vanish if economic recession replaced economic recovery.

This argument that Reagan must strike quickly is also an argument against a new cast. Keeping Baker and his team, with their experience and political skills, would enable Reagan to avoid on-the-job training in the honeymoon phase and be quick off the mark in dealing with Congress. This argument is likely to be even more appealing if Deaver, chairman of the shadow inaugural committee, decides that it is finally time for him to take a more lucrative job outside the White House.

Nor are large changes foreseen in a Cabinet that, with a few conspicuous exceptions, has earned a reputation for mediocrity. Reagan is not one to emulate the example of Richard M. Nixon and ask for everyone's resignation so he can shuffle the political deck.

In large measure, it is the cast that determines the performance. Keeping Baker would be an augury of budget compromise. Keeping Defense Secretary Caspar W. Weinberger, who can probably stay as long as he wants, is a sign that arms-control agreements with the Soviet Union will not come easily in a second term. Keeping William J. Casey as CIA director, as Reagan has promised to do, and U.N. Ambassador Jeane J. Kirkpatrick in a high-level post, as Reagan desires, are signs that he will not abandon his goals in Central America.

None of this is necessarily cast in concrete, partly because Reagan is too superstitious and too prudent to focus on a second term he has yet to win. In deference, White House and campaign aides ritually warn each other not to become overconfident. After a rare prediction of victory at a Gulfport, Miss., rally last week, the president returned the next day to his bromide that "President Dewey warned me not to get overconfident."

Behind the scenes, however, the stars and bit players of the first term are casting for the sequel at the White House. If Reagan wins, it's likely that you'll recognize both the plot and the players.

Reaganism of the Week: Speaking at Texas Southmost College in Brownsville last week, Reagan was given a new pair of cowboy boots by Rep. Phil Gramm (R-Tex.), Republican nominee for the U.S. Senate.

After thanking him, Reagan said: "Some recently have tried to suggest that I have a ranch where I just walk around and look at the scenery or something, and they've made the mistake of saying that in front of Nancy one day . . . . She challenged them to come out and follow me morning to dusk any afternoon and see what I do."