(mfp_igor_scripts) Scripts committed
[hooke.git] / flatfilts.py
index 0cb70cec6651890656d1ae3d93798d559d9bafa7..b287527efb0212e512290e962d714460461ce4a1 100755 (executable)
@@ -147,11 +147,15 @@ class flatfiltsCommands:
     #-----Convolution-based peak recognition and filtering.
     #Requires the libpeakspot.py library
     
-    def has_peaks(self, plot, abs_devs):
+    def has_peaks(self, plot, abs_devs=None):
         '''
         Finds peak position in a force curve.
         FIXME: should be moved in libpeakspot.py
         '''
+        if abs_devs==None:
+            abs_devs=self.convfilt_config['mindeviation']
+        
+        
         xret=plot.vectors[1][0]
         yret=plot.vectors[1][1]
         #Calculate convolution.
@@ -253,8 +257,10 @@ class flatfiltsCommands:
         recplot.vectors.append([xgood,ygood])
         if recplot.styles==[]:
             recplot.styles=[None,None,'scatter']
+            recplot.colors=[None,None,None]
         else:
             recplot.styles+=['scatter']
+            recplot.colors+=[None]
         
         self._send_plot([recplot])