Test ROCAUC without a micro average
// Load the Data
X_train, X_test, y_train, y_test = self.load_binary_data()
// Create and fit the visualizer
visualizer = ROCAUC(LogisticRegression(), micro=False)
visualizer.fit(X_train, y_train)
After Change
// TODO: image comparison of the quick method
roc_auc(model, data.data, data.target)
def test_rocauc_no_micro(self):
Test ROCAUC without a micro average
// Create and fit the visualizer
visualizer = ROCAUC(LogisticRegression(), micro=False)
visualizer.fit(self.binary.X.train, self.binary.y.train)
// Score the visualizer (should be the macro average)
s = visualizer.score(self.binary.X.test, self.binary.y.test)
self.assertAlmostEqual(s, 0.8)
// Assert that there is no micro score
self.assertNotIn("micro", visualizer.fpr)