freq stat plot legend fix