mutual information and figure plotting