Tests of clients in two Baltimore clinics that treat sexually transmitted disease (STD) have shown that the AIDS virus appears to be spreading heterosexually among that city's black population.

As reported last week in the New England Journal of Medicine, slightly more than 5 percent, or about 1 in 20, of some 4,000 new clients walking through the STD clinic doors in Baltimore last spring were infected with human immunodeficiency virus (HIV), which causes acquired immune deficiency syndrome. Ninety-four percent of the clinic's clients are black.

More than half of the infected women and a third of the infected men in the Baltimore study did not fit into any of the groups most at risk for AIDS -- homosexuals, intravenous drug users and their sexual partners. Authors of the study conclude that a significant number became infected during heterosexual encounters.

In another report, preliminary results from a statewide survey of STD clinics in Maryland found that 2.3 percent of the new clients were HIV-infected, said Diane Matuszak, chief of community epidemiology at the Maryland Department of Health and Mental Hygiene. Details as to race, risk group or an indication of heterosexual spread are not yet available because the study was recently completed and is not fully analyzed, Matuszak said. The final results should become available in the next few months.

The new Baltimore and Maryland data are two pieces in the puzzle of how far AIDS will spread outside of the groups it has already devastated. Health officials point out that people entering STD clinics are not representative of the general population. They tend to be more sexually active and already have a venereal disease. Many are impoverished.

But the findings of the two studies are important because they show that heterosexual transmission of the virus is occurring -- a way of spreading the infection that is common in AIDS-ravaged Africa and parts of the Caribbean.

In addition to the Maryland survey, similar findings in other STD clinics have been reported. During a month-long survey last May, the Virginia Department of Health found that 2 percent of those attending the state's STD clinics carried HIV in their bodies.

Comparable information is not yet available in the District of Columbia. "We really don't have any idea of what the seroprevalence {a measure of those infected} is," said Dr. Reed Tuckson, commissioner of the D.C. Commission of Public Health.

Late last week, Tuckson said that the city had just been notified by the Centers for Disease Control in Atlanta that it will be part of a federally funded study to measure how widely the AIDS virus has spread throughout the nation.

"We expect to begin that within the next month or so," Tuckson said.

The long-awaited and much debated "30-cities study" will be conducted by the CDC and will anonymously test individuals throughout the country to measure how far the virus has spread. The study will be ongoing so that changes in the infection rates can be identified.

Twenty cities have been selected in areas of the country where AIDS is common and and 10 in areas with relatively few cases. Among the other cities in the study will be Richmond, Baltimore, New York and San Francisco.

The general population in each city will not be randomly tested. Instead, testing will focus on those coming into STD clinics, tuberculosis clinics, prenatal and maternal care clinics and drug and alcohol abuse treatment programs.

According to CDC spokesman Chuck Fallis, funding for the studies was finally made available yesterday.

Testing blood for signs of the virus provides a better understanding of who has become infected than does analyzing the distribution of actual AIDS cases. It takes years, sometimes five or more, for the infection to lead to actual symptoms. Based on studies in San Francisco, physicians predict that at least half of those infected with HIV will go on to develop the disease within a decade after infection. For more than a year and a half, the U.S. Public Health Service has been been using the estimate that between 1 million and 1.5 million Americans already have been infected with HIV.

So far, that estimate has held up, with the number of AIDS cases growing as predicted. As of Jan. 25, 51,916 cases of AIDS had been reported to the CDC since 1981; 28,965 had died.

The 30-cities survey, along with ongoing surveys in certain hospitals, is critical because it can be used to predict how many Americans are likely to become sick. It can also be used to target certain population groups for intense education programs to prevent the spread of the virus. In addition, the survey will be a way to determine whether education programs are slowing HIV's spread.

The most detailed knowledge about who is currently infected with the virus comes from testing the blood of military recruits and blood donors and from the Baltimore study of STD clinics.

Recruits for military service are routinely tested for HIV infection. Recruits from the Middle Atlantic Region were found to be infected 0.29 percent of the time. In Baltimore, the infection rate was higher. Some 1.2 percent of the military recruits from the inner city tested positive for carrying the AIDS virus. Officials caution that because recruits are a self-selected group primarily composed of young men, they do not represent the distribution of HIV in the general population.

Studies among blood donors indicate that the infection rate is almost negligible -- four in every 10,000 (0.04 percent) are infected with HIV.

The Baltimore STD clinic study provides some of the most detailed data of any study so far published.

Of the more than 4,000 clients tested in the initial study, 209 were positive, indicating they were infected with HIV. Of those infected, 170 were men; 39 were women.

"The rate was four to five times higher than the rate of HIV infection among military applicants in Baltimore," said Dr. Thomas Quinn of the National Institute of Allergy and Infectious Disease and Johns Hopkins University School of Medicine, who headed the study.

In addition to the usual risk factors, HIV infection also was correlated with syphilis and hepatitis in men and with genital warts in women. Quinn said this association strengthens the hypothesis that if the epithelial lining of the genitals is damaged, the AIDS virus has more direct access to the person's bloodstream, increasing the chances of infection. "Lesions in the genital tract make it easier to pass HIV," he said. The disease, however, is still more difficult to pass from a woman to a man than from a man to a woman.

Nearly all of those infected were black, reflecting the inner-city STD clinic's primary clients. "We don't have any data to show what is happening in the white community," Quinn said. "Ninety-four percent of the patients attending the clinic were black. The remaining 5 to 6 percent were white." Only two whites were infected with the AIDS virus.

Quinn was reluctant to use the Baltimore study to predict what might be occurring in the rest of the country, but he did say he "would not be surprised" to find very similar data if such a survey were conducted in other East Coast inner-city populations with a large number of intravenous drug users.

Quinn said: "If we did the same study in Washington, D.C., we would find similar rates of HIV infection in patients attending the STD clinics."

The populations of the inner cities of Washington and Baltimore are very similar. Washington also has a major problem with drugs: The D.C. health commission estimates there are some 16,000 intravenous drug users in the city. "The virus is moving into the heterosexual community via the intravenous drug users," Quinn said.

Washington also has a significant problem with sexually transmitted diseases. According to 1985 statistics, the most recent available, the District had a higher rate of gonorrhea than any other major city in the United States but came in third, behind Atlanta and Newark, N.J., in the rate of syphilis cases.

Despite the high prevalence of HIV risk factors in the District, said Commissioner Tuckson, the distribution of AIDS cases has remained constant: 81 percent of the AIDS cases in the district are among homosexuals; 8 percent among intravenous drug users; 7 percent among homosexuals who inject drugs; 2 percent among heterosexuals; 1 percent among those receiving transfusions; 1 percent other.

A disturbing footnote from the Baltimore study is the lack of condom use. More than half (54.5 percent) of men going to the Baltimore STD clinics said they never used condoms; 42.3 percent said they sometimes used condoms and only 3.2 percent said they always used condoms. Among the women, 67.7 percent said they never used condoms; 28.1 percent said sometimes and only 4.2 percent always.