From Business Insider:

Crowdpac, a non-partisan firm dedicated to political data analysis, used federal campaign contribution records dating back to 1980 in order to estimate where various officials and donors fall on the political spectrum. They scored individual donors as being more liberal or conservative based on what kinds of candidates they gave to.

The company’s CEO and co-founder, Steve Hilton, told Business Insider this donation data “is the heart of the Crowdpac data model” because their “research shows that campaign contributions are the best predictor of how a candidate will behave in office.” …

As part of their analysis, Crowdpac is also able to break down where various professions fall on the political spectrum. They provided that data to Business Insider.