File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed
Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -640,14 +640,18 @@ def enumticks(a):
640640 return None
641641 return [[(x , f"{ x :.2f} " ) for x in a [::- 1 ]]]
642642
643- data = self .curve_data ( self . target_index , self . selected_classifiers [ 0 ] )
644- points = data . merged . points
643+ axis_bottom = self .plot . getAxis ( "bottom" )
644+ axis_left = self . plot . getAxis ( "left" )
645645
646- axis = self .plot .getAxis ("bottom" )
647- axis .setTicks (enumticks (points .fpr ))
648-
649- axis = self .plot .getAxis ("left" )
650- axis .setTicks (enumticks (points .tpr ))
646+ if not self .selected_classifiers or len (self .selected_classifiers ) > 1 \
647+ or self .roc_averaging != OWROCAnalysis .Merge :
648+ axis_bottom .setTicks (None )
649+ axis_left .setTicks (None )
650+ else :
651+ data = self .curve_data (self .target_index , self .selected_classifiers [0 ])
652+ points = data .merged .points
653+ axis_bottom .setTicks (enumticks (points .fpr ))
654+ axis_left .setTicks (enumticks (points .tpr ))
651655
652656 def _on_mouse_moved (self , pos ):
653657 target = self .target_index
You can’t perform that action at this time.
0 commit comments