Fixed problem with plots accumulating.
This commit is contained in:
@@ -282,6 +282,7 @@ class ScatterPlot(Plot):
|
|||||||
index = [ind for id,ind in self.dataset[self.current_dim].items() if id in ids] #conversion to index
|
index = [ind for id,ind in self.dataset[self.current_dim].items() if id in ids] #conversion to index
|
||||||
xdata_new = scipy.take(self.xaxis_data,index) #take data
|
xdata_new = scipy.take(self.xaxis_data,index) #take data
|
||||||
ydata_new = scipy.take(self.yaxis_data,index)
|
ydata_new = scipy.take(self.yaxis_data,index)
|
||||||
|
self.ax.clear()
|
||||||
self.ax.plot(self.xaxis_data,self.yaxis_data,'og')
|
self.ax.plot(self.xaxis_data,self.yaxis_data,'og')
|
||||||
self.ax.plot(xdata_new,ydata_new,'or')
|
self.ax.plot(xdata_new,ydata_new,'or')
|
||||||
self.canvas.draw()
|
self.canvas.draw()
|
||||||
|
Reference in New Issue
Block a user