It could be possible that the Judge or Magistrate would be a man of high standing, authority & man of intelligence & learning in the community. A Doctor or surgeon, Chemist (clergy?) would be known as a 'Beak' (dating from the plague years) & in slang, the name stuck as a generic term.