diff --git a/doc/api/animation_api.rst b/doc/api/animation_api.rst index ddc5631c1b15..5a3d53442fde 100644 --- a/doc/api/animation_api.rst +++ b/doc/api/animation_api.rst @@ -111,7 +111,7 @@ artist at a global scope and let Python sort things out. For example :: fig, ax = plt.subplots() xdata, ydata = [], [] - ln, = plt.plot([], [], 'ro') + ln, = ax.plot([], [], 'ro') def init(): ax.set_xlim(0, 2*np.pi)