[5][6] While still a teacher, Dean also began to study law with James M. Bell and D. H. Hoffius in Hollidaysburg, Pennsylvania.
[11] From 1849 until 1864, he practiced law in Hollidaysburg in partnership with Samuel Steel Blair, who later became a member of the U.S. House of Representatives.
[12] In May 1857, Dean was elected to a three-year term as superintendent of his county's public schools; however, he resigned after a year in order to return to his private law practice.
[13] A member of the Republican Party, Dean was appointed as district attorney for Blair County in 1867 to fill a vacancy created by the resignation of John H. Keatley, and was then elected to that same office in 1868, serving for three years in that capacity.
[14][15] In 1871, Dean was elected president judge of the Twenty-fourth Judicial District,[16] and subsequently reelected to that post in 1881 and 1891.