Dr. Brian D. Blackbourne, the District's deputy chief medical examiner for the last 11 1/2 years, said yesterday he is leaving that position and will be sworn in this morning as the first chief medical examiner for the state of Massachusetts.

Blackbourne, 44, and his boss, chief D.C. medical examiner James L. Luke, have largely been credited with the transformation of the District's morgue over the last decade into a highly professional agency that annually unlocks the mysteries of about 1,000 deaths in the city.

Blackbourne, whose salary will increase from $62,000 here to $93,000 annually in Massachusetts, was nominated by a search committee and appointed by Gov. Edward J. King, who leaves office on Thursday. Blackbourne, who also will be a professor at the University of Massachusetts Medical Center in Worcester, has a seven-year term in his new job.

While working for Washington, and in a similar position earlier in Miami, Blackbourne has focused much of his attention on studying the causes of fatal accidental injuries to children and how people die in car accidents. He said that some of his research, along with that of others, eventually led manufacturers to narrow the distance between slats in baby cribs. Numerous infants had died when their heads became trapped between too-wide slats.

But most of Blackbourne's work in the District medical examiner's office has fallen toward that of a detective, trying to solve the puzzle of an unexplained death. In one such case, Blackbourne discovered in an autopsy, one of about 200 a year he performed, there was a good reason why a man had died of sudden, rapid failure of his heart and circulatory system.

It turned out the man had 10 packets of cocaine in his stomach wrapped in six layers of condoms. The man had smuggled the cocaine out of Colombia, but had made the packets so large they could not pass through his digestive system. Eventually, digestive acid had eaten through one package and the man suddenly had three grams of 68 percent cocaine in his stomach, causing his seizures and collapse.