ヘルプから:matplotlibでは、set_xlimとset_xboundの違いは何ですか?
set_xlim: xaxisのデータ制限を設定します。
set_xbound: x軸の下限と上限の数値境界を設定します。
非常に明確ではありません、それでは、私が何かプロットとしましょう:今すぐ
import matplotlib.pylab as plt
fig, ax = plt.subplots(1, 1)
ax.plot(xrange(10), xrange(10))
を、どちらか私は:
ax.set_xlim(2, 7)
か:
ax.set_xbound(2, 7)
私は違いを見ないでください。私はプロットをドラッグすることができます、すべての行は0と9の間に表示されます。
[Axes.set_xbound(http://matplotlib.sourceforge.net/api/axes_api.html#matplotlib.axes.Axes.set_xbound)は([Axes.set_xlim]使用しますhttp://matplotlib.sourceforge.net/api/axes_api.html#matplotlib.axes.Axes.set_xlim)[code](https://github.com/matplotlib/matplotlib/blob/master/lib)を見てください。 /matplotlib/axes.py#L2355) – adchilds