confusion_matrix_metrics
Compute confusion matrix, accuracy, precision, and recall for both breast-cancer models on the test set, including malignant-class precision/recall and actual rows versus predicted columns.
Instructions
Compute the confusion matrix plus accuracy/precision/recall for both models on the test set. Precision and recall are for the malignant class. Confusion matrix order is [malignant, benign]; rows = actual, columns = predicted.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| test_size | No | Fraction of the data held out for testing. | |
| request_id | No | Your own id for this call; recorded in the audit log. | unknown |
| random_state | No | Random seed for the train/test split. | |
| knn_neighbors | No | Number of neighbors for the KNN model. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |