A recent book by Lone Frank called The Pleasure Shock: The Rise of Deep Brain Stimulation and its Forgotten Inventor, tells the story of Dr. Robert Heath, who was the head of psychiatry at Tulane University beginning in 1949. Heath pioneered the practice of stimulating the brain with electrodes. He experimented on mentally ill patients throughout the 1950s and 1960s in ways that today would be considered unethical.
His most notorious case was that of a man who was mentally ill, abused drugs, lived off the favors of gay men, and was suicidal. While the man was at Charity Hospital, Heath tried to use electrical stimulation of the brain to change him to a heterosexual. The case only became public in 1972, soon after which Heath's work was held up as an example of unethical human subjects research.
This particular instance with its sexual dimension would have been a perfect influence for Confederacy had it been public before 1963; however, there may have been other instances from the 1950s that could have influenced Toole. Heath first presented his electrical stimulation research at a symposium in New Orleans in 1952. Throughout the 1950s, he experimented with combinations of stimulation and hallucinogenic drugs on the mentally ill in New Orleans. If any of this work became public, or was known through gossip, it could have influenced Toole. (Note: the descriptions of actions at Charity in the novel do not include electrical stimulation, so there is no direct reference to the practice in the novel.)
Another possible, even likely, influence on Toole's portrayal of psychiatric treatment was Ken Kesey's One Flew over the Cuckoo's Nest, which was published in 1962, just before Toole wrote most of Confederacy in 1963.
Thesis: Explore the public understanding of psychiatry and the treatment of patients at psychiatric hospitals up to 1963. Might the specific culture of psychiatric treatment in New Orleans have made this theme especially relevant to Confederacy of Dunces?