President Carter and Ronald Reagan limped out of Texas today, still moving steadily toward their parties' nominations but showing scars from a dissatisfied electorate.

Reagan may have left in better shape than the president, despite the strong showing made by George Bush in the popular vote in Saturday's Republican primary.

Carter, who appears headed for a big victory in the state's delegate selection process that began Saturday night, must reckon with the large number of Texas voters who indicated that deep in their hearts they preferred "uncommitted" to either the president or his challenger, Sen. Edward M. Kennedy, in Saturday's separate nonbinding beauty contest.

Fully a fifth of those who participated in that contest rejected both Carter and Kennedy. Because the vote had nothing to do with selecting delegates, the Texans clearly were signalling their discontent.

Bush, campaigning today in North Carolina, said he was, "stunned, pleasantly" at his Texas showing, but conceded that finishing second isn't enough to win the nomination.

The next tests will come Tuesday in the District of Columbia, Indiana, Tennessee and North Carolina. Reagan and Carter are favored to win a substantial majority of the delegates at stake.

Reagan can take heart from his big delegate victory and the sizable GOP turnout in districts won by Bush, but which are likely to stay strongly Republican in November.

Yet Reagan's failure to eliminate Bush in a state that gave him his biggest delegate victory in 1976 makes it likely that the former California governor will be the target of protest votes in later primaries against Bush, and could arrive at the Republican convention in July tarnished.

Bush's Texas showing makes it almost certain he will stay in the race through the rest of the primaries -- a development disturbing to Reagan's advisers, who have been working on a general election strategy for weeks.

James Baker, Bush's campaign manager, said today the results in Texas increased the possibility that Bush would challenge Reagan in the winner-take-all California primary on June 3, where Reagan has been overwhelmingly favored to win the 168 delegates.

"We were behind in Texas 75-25 two weeks ago," Baker said. "To have this kind of finish in the face of that is encouraging. We don't for one minute buy the argument that California is not winnable.It just doesn't wash, in light of the results in Pennsylvania and Texas."

Bush came from far back to upset Reagan in the popular vote in Pennsylvania's April 22 primary.

Baker said the main question about running in California is money, but that Saturday's results "should enable us to raise the money we have to raise to run the kind of campaign we want to run in California."

Bush's only advantage over Reagan at this point is his ability to spend money. Unlike Reagan, he is not bumping up against the federal spending ceiling.That means he can run aggressive media campaigns, as he did in Texas and Pennsylvania, while front-runner Reagan is forced to maintain a low budget profile.

Reagan was unable to escape a psychological bruising in Texas because of this, and the same thing could happen in other states, even though Reagan takes the majority of the delegates. Baker said Bush next will concentrate on Michigan and Oregon, whose primaries are held May 20.

Bush's showing in Texas was not as broadly based as the overall figures indicate, and his early lead resulted entirely from a quick count in the 7th Congressional District around Houston, which Bush represented in Congress and where he has lived for much of the last 32 years.

Bush was the apparent winner in only five of the state's 24 congressional districts, four of them around Houston, and the fifth in Austin. Despite extensive campaigning in the Dallas area, he failed to beat Reagan in any of those districts.

Here are the Republican results, with 2,981 of 3,022 precincts, or 99 percent, reporting:

Reagan, 263,616 or 52 percent.

Bush, 237,379 or 47 percent.

Uncommitted, 7,923 or 1 percent.

Reagan appeared to have won 19 districts, worth three delegates each, and as the overall winner, will receive eight additional delegates. That means he is likely to win 65 of the state's 80 delegates, with 15 going to Bush. According to a United Press International count, Reagan now has 692 delegates toward nomination, and Bush 142.Needed to nominate are 998.

Here are the Democratic results, with 5,809 of 5,811 precincts, or 99 percent, reporting:

Carter, 766,704 or 56 percent.

Kennedy, 10,701 or 22 percent.

Calif. Gov. Edmund G. Brown Jr., 35,727 or 3 percent.

Uncommitted, 256,240 or 19 percent.

Texas Democrats met in precinct conventions Saturday night, the first step in a three-tier process used to pick the 152 delegates who will go to the national convention. Results were scattered and the outcome may not begin to be clear until next Saturday's county convention. The Texas delegation will be chosen finally at a state convention June 20 and 21.

Carter campaign officials said they believe that on the basis of the precinct conventions, they would win 100 to 110 delegates.

The Kennedy camp disputed this. Bill Carrick, the Kennedy coordinator in Texas, said it appeared today that Kennedy had captured 40 delegates and Carter 60 delegates, with the rest up for grabs.

Kennedy, campaigning doggedly through Indiana, played down Saturday's election results.

"We've had limited resources in Texas," Kennedy said. "All of our energies were devoted toward the delegate selection process. . . . The race is going to tighten up significantly in Texas before the final delegates are chosen."