A confusion matrix is an approach that gives a brief statement of prediction results on a binary and multi-class classification problem. Let's assume we have to find out whether a person has diabetes or not. The concept behind the confusion matrix is to find the number of right and mistaken forecasts, which are further summarized and separated into each class. It clarifies all the confusion related to the performance of our classification model. This 2x2 matrix not only shows the error being made by our classifier but also represents what sort of mistakes are being made. A confusion matrix is used to make a complete analysis of statistical data faster and also make the results more readable and understandable through clear data visualization. It contains two rows and columns, as shown in the following list. Let's understand the basic terminologies of the confusion matrix:
- True Positive (TP): This represents cases that are forecasted as Yes and in...