pad_inches=0 and bbox_inches=“tight” makes the plot smaller than declared figsize

前端 未结 3 1085
死守一世寂寞
死守一世寂寞 2020-12-08 07:10

I am producing a publication-quality plot to be embedded in latex and I would like to be very precise in terms of sizes and fonts (so that fonts are of the same size in the

3条回答
  •  轮回少年
    2020-12-08 08:13

    The problem you are having is that bbox_inches='tight' just removes all of the extra white space around your figure, it does not actually re-arrange anything in your figure, after it has been rendered.

    You might need to tweak the parameters you pass to tight_layout (tutorial) to get your desired effect.

    Hopefully this gets you pointed in the right direction.

提交回复
热议问题