【问题标题】:How to change font size of the annotation in seaborn jointplot?如何更改 seaborn 联合图中注释的字体大小?
【发布时间】:2016-12-26 14:41:48
【问题描述】:

我正在使用 -

制作带有回归线的联合图
sns.jointplot(xdata,ydata,kind='reg', order=2,ylim=[-1,1],xlim=[-1,1],annot_kws={"loc": 4})

我可以使用annot_kws 更改位置,但无法更改字体大小。如何更改字体大小?

【问题讨论】:

    标签: python annotations font-size seaborn


    【解决方案1】:

    在绘制之前,我可以通过更改 matplotlib 的默认图例字体大小来更改字体大小。

    matplotlib.rc("legend", fontsize=20)
    sns.jointplot(xdata,ydata,kind='reg', order=2,ylim=[-1,1],xlim=[-1,1],annot_kws={"loc": 4})
    

    【讨论】:

      猜你喜欢
      • 2020-09-14
      • 1970-01-01
      • 1970-01-01
      • 2014-10-09
      • 2016-03-09
      • 1970-01-01
      • 2016-09-11
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多