File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -137,19 +137,19 @@ def commit(self):
137137 data_output = None
138138 self ._save_selected (actual = True )
139139
140+ data = self .data or self .classifier and self .classifier .instances
140141 if (self .selected is not None and
141- self . data is not None and
142+ data is not None and
142143 self .classifier is not None and
143- self . data .domain .attributes ==
144+ data .domain .attributes ==
144145 self .classifier .original_domain .attributes ):
145146
146- status = np .ones (self . data .X .shape [0 ], dtype = bool )
147+ status = np .ones (data .X .shape [0 ], dtype = bool )
147148 for i in self .selected :
148149 rule = self .classifier .rule_list [i ]
149- status &= rule .evaluate_data (self . data .X )
150+ status &= rule .evaluate_data (data .X )
150151
151- data_output = self .data .from_table_rows (
152- self .data , status .nonzero ()[0 ])
152+ data_output = data .from_table_rows (data , status .nonzero ()[0 ])
153153
154154 self .send (OWRuleViewer .data_output_identifier , data_output )
155155
You can’t perform that action at this time.
0 commit comments