Issue
Here is my question:
I plot 7 variable's coefficient using sns.clustermap()
- x/y tickslabel seems really small(In my case, s1,s2,... s9)
My attempt
label='big
==> no effect- plt.tick_params(axis='both', which='minor', labelsize=12) ===> cbar label has changed, but the x/y axes looks the same.
Add
My code:
ds = pd.read_csv("xxxx.csv")
corr = ds.corr().mul(100).astype(int)
cmap = sns.diverging_palette(h_neg=210, h_pos=350, s=90, l=30, as_cmap=True)
sns.clustermap(data=corr_s, annot=True, fmt='d',cmap = "Blues",annot_kws={"size": 16},)
Solution
Consider calling sns.set(font_scale=1.4)
before plotting your data. This will scale all fonts in your legend and on the axes.
To this,
Of course, adjust the scaling to whatever you feel is a good setting.
Code:
sns.set(font_scale=1.4)
cmap = sns.diverging_palette(h_neg=210, h_pos=350, s=90, l=30, as_cmap=True)
sns.clustermap(data=corr, annot=True, fmt='d', cmap="Blues", annot_kws={"size": 16})
Answered By - Nelewout
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.