gpt4 book ai didi

machine-learning - 为什么数字从我的 Seaborn 热图中移出?

转载 作者:行者123 更新时间:2023-11-30 10:00:42 29 4
gpt4 key购买 nike

sns.heatmap(metric, annot=True ,fmt='g', cmap ="Blues")
plt.title('Confusion matrix')
plt.ylabel('Actual label')
plt.xlabel('Predicted label')

我正在尝试绘制我的热图,但我的数字看起来非常难看! enter image description here

最佳答案

您尝试过对数据集进行 corr 吗?如下所示

sns.heatmap(df.corr(),cmap='coolwarm',annot=True)

关于machine-learning - 为什么数字从我的 Seaborn 热图中移出?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59160754/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com