Understanding Confusion Matrix in scikit-learn
The confusion matrix is a tool to assess how well a classification model performs by measuring how many times instances are classified correctly or incorrectly. Let's dive into more details about how to use this with scikit-learn.
What is a Confusion Matrix?
A confusion matrix is a summary of prediction results on a classification problem. The number of correct and incorrect predictions are summarized with count values broken down by each class.
Key Terms
- True Positive (TP): Correctly predicted positive observations.
- True Negative (TN): Correctly predicted negative observations.
- False Positive (FP): Incorrectly predicted positive observations.
- False Negative (FN): Incorrectly predicted negative observations.