After studying medicine at University of Edinburgh, James Barry made a name for himself as a top army surgeon in the early to mid-1800s. He worked all over the world, from Cape Town, South Africa, to Trinidad and Tobago. Barry was known as a bad-tempered, eccentric person by his colleagues, and he was often teased until he shot one of his tormentors dead. Despite the common dislike of Barry, he was a well-liked doctor and ended his career as Inspector General of military hospitals.

James Barry died of a severe stomach illness in 1865. That’s when the mystery began to unfold. As his maid prepared him for the funeral, she made the startling discovery that he was actually a woman. Some colleagues maintained that they knew Barry’s true identity all along, while most were shocked by the revelation. James Barry was born Margaret Ann Bulkley in Ireland. She planned to disguise herself as a man to study medicine in Edinburgh, then travel to Venezuela to practice medicine as a woman. With a letter of recommendation in hand from the prestigious Lord Buchan, Margaret and her mother took a boat to Leith, near Edinburgh, and organized her disguise. Margaret’s plans were interrupted when General Francisco de Miranda, to whom her family had ties, failed in his attempt to liberate Venezuela. Margaret decided to continue in her disguise as James Barry and join the army, where she spent the rest of her life as James Barry.

D.R. McKinnon was Barry’s doctor and the one who ultimately wrote “male” on the death certificate. When asked if he knew the truth about Barry’s gender, McKinnon said that he never had any suspicion that Dr. Barry was female, but that it wasn’t his business either way. Shortly after his death, a woman who worked at the hospital performed the last offices—to confirm that Barry was dead—and said that she believed he was actually a female and had marks that indicated she had given birth at a young age. No information has ever been found about a possible child of Margaret Ann Bulkley. Over a century later, it is still unknown whether Margaret changed her gender identity and considered herself to be a man, or if she was simply undercover for all those years.