1

Using heatmap from seaborn I would like to centralized both: values on chart and y-axes values. Many thanks for any tips.

import numpy as np
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt

test=np.matrix('10000 20000;30000 40000')

df_cm = pd.DataFrame(test, index = [i for i in "01"], columns = [i for i in "01"])
plt.figure(figsize = (5,3))
cf_heatmap=sns.heatmap(test, annot=True, fmt='n', annot_kws={"size":12}, linewidths=.5, vmin=0,vmax=50000, center=False, cmap='RdBu_r').set(title='TITLE')
plt.ylabel('fff')
plt.xlabel('yyy')
Kaustubh Lohani
  • 635
  • 5
  • 15
Paweł
  • 11
  • 1

0 Answers0