2018-11-08から1日間の記事一覧
ax = plt.gca() ratio = 0.618 xleft, xright = ax.get_xlim() ybottom, ytop = ax.get_ylim() ax.set_aspect(abs((xright-xleft)/(ybottom-ytop))*ratio) 【参考】 How to Change the Aspect Ratio of Image (or Axes) in Matplotlib? - jdhao's blog