Ronald Reagan campaigned today in gloomy weather, which matched some of the omens for his own candidacy.

In his first week of campaigning, against a newly renominated incumbent president, Reagan found himself sagging in the polls, pressed by independent candidate John B. Anderson in the key state of Illinois and unable to get across a clear message of his position on defense and foreign policy.

Even some of Reagan's advisers acknowledge that the impact of a speech Monday intended to define his national security policy was at best diffused.

"When there are seven different versions of what we've done presented by the national press, we're not accomplishing our purpose," an aide said.

The aide was referring to the varied accounts on television networks and in major newspaper of Reagan's speech to the Veterans of Foreign Wars convention. Some accounts stressed "peach through strength" advocacy, others the alleged failures of President's Carter's foreign policies, and still others Reagan's comment that the Vietnam War had been "a nobel cause."

Reagan's advisers intended to use the speech as a message that a Reagan administration would bolster U.S. military defense, restoring the "margin of safety" supposedly lost under the Carter administration, while at the same time, displaying a readiness to negotiate with the Soviets.

But the speech appeared to have been written by committee. It emphasized the necessity of participating in the arms race at some point and the necessity of negotiation with the Soviets at others. Largely devoid of specifics, it failed to summarize how Reagan would restore the "margin of safety" he said had been lost.

Today, Reagan tried again. Under cloudy skies, he campaigned at a shipyard here and used the occasion to discuss the decline of the U.S. maritime fleet.

"Should our shipbuilding capability continue to decline, American mobilization potential in case of an emergency will be seriously undermined because a large reduction in a skilled shipbuilding work force today makes any increase tomorrow very difficult," Reagan told an attentive and friendly audience of 3,000 shipyard workers.

"This is a dangerous threat to our national security, to jobs and to a key U.S. industry."

Again, Reagan's "eight point" program contained few specifics. He said that if he is elected president he would convene a conference of maritime and shipbuilding leaders in an effort "to build a merchant marine consistent with our economic, trade and national security needs."

Reagan also said he would "appoint men and women to federal posts which impact directly on shipbuilding, who are people who have experience in the field and who knows what they're talking about. All too often the right people have not been put in the right slots."

Reagan brushed aside his slippage in several national polls, saying, "It's natural that after a convention there is an upsurge."

In Illinois, where Reagan campaigned at a GOP fund-raiser Monday Illinois campaign chairman Don Totten expressed concern in separate interviews that Anderson's candidacy was hurting Reagan.

"John Anderson's a factor in Illinois," said Totten. "He hurts us more than he does Carter here. If his star ascends it will be tough for us. If it descends we'll win it."

Thompson predicted that Anderson would fade but agreed he could cost Reagan votes in suburban areas and the Chicago North Shore. The governor, however, seemed concerned about Reagan's discussion of the Vietnam War, saying with a smile that "I don't think I'd lay heavy stress on that during the campaign."

Asked his own view, Thompson replied: "I think the war is over."

In his brief remarks to the GOP fund-raiser, Reagan inadvertently referred to "Dave Thompson" giving the governor the first name of his lieutenant governor, Dave O'Neal.

The Reagan transcript of his remarks omitted the error. When a television reporter complained to Reagan press secretary Lyn Nofziger about the omission, Nofziger apologized and said it wouldn't happen again.