When a hospital computer catches a virus, the results can be hazardous to patients' health, a doctor says.

In a letter in the New England Journal of Medicine, a radiologist described what happened when computers used for analyzing patients' nuclear scans were infected with two computer viruses.Computer viruses are devious pieces of computer code that move from machine to machine, often reproduce themselves and sometimes make computers sick.

Although this time the infection was cured without lasting harm, Dr. Jack E. Juni said potential damage was serious.

"The information on these machines was the actual scans we were using to make diagnoses," he said in an interview. "If the data had been lost, it would have affected the diagnoses of patients."

One of the viruses was relatively benign, making copies of itself while leaving other information in the computer alone. However, the other virus inserted itself into programs and directories of patient information and made the machines malfunction.

Juni, of William Beaumont Hospitals in Royal Oak, Mich., said about three-quarters of the programs stored in two Macintosh II personal computers were infected.

He said he did not know the origin of the less harmful virus, but the more serious one apparently was on the hard disk of one of the computers when the hospital had bought it. A hard disk is the internal device used by computers to store programs and data. The virus spread from one computer to another when a doctor used a word processing program on both machines while writing a medical paper.

Juni said the virus caused occasional random malfunctions. Sometimes the computers would freeze up or garble patients' names.

The hospital had backup copies of patient records and eventually purged the viruses from the computers. It has since instituted precautions in an effort to keep out viruses.