Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e43512e commit 48b48adCopy full SHA for 48b48ad
1 file changed
examples/pylab_examples/cursor_demo.py
@@ -57,7 +57,7 @@ def mouse_move(self, event):
57
58
x, y = event.xdata, event.ydata
59
60
- indx = searchsorted(self.x, [x])[0]
+ indx = np.searchsorted(self.x, [x])[0]
61
x = self.x[indx]
62
y = self.y[indx]
63
# update the line positions
@@ -66,7 +66,7 @@ def mouse_move(self, event):
66
67
self.txt.set_text('x=%1.2f, y=%1.2f' % (x, y))
68
print('x=%1.2f, y=%1.2f' % (x, y))
69
- draw()
+ plt.draw()
70
71
t = np.arange(0.0, 1.0, 0.01)
72
s = np.sin(2*2*np.pi*t)
0 commit comments