in Education by
What is a confusion matrix? Explain in detail with the help of an example. Select the correct answer from above options

1 Answer

0 votes
by
 
Best answer
Confusion Matrix: A Confusion Matrix is a table that is often used to describe the performance of a classification model (or "classifier") on a set of test data for which the true values are known. (or) A 2x2 matrix denoting the right and wrong predictions might help us analyse the rate of success. This matrix is termed the Confusion Matrix. Evaluation of the performance of a classification model is based on the counts of test records correctly and incorrectly predicted by the model. Therefore, Confusion Matrix provides a more insightful picture which is not only the performance of a predictive model, but also which classes are being predicted correctly and incorrectly, and what type of errors are being made. The confusion matrix is useful for measuring Recall (also known as Sensitivity), Precision, Accuracy and F1 Score. The following confusion matrix table illustrates how the 4-classification metrics are calculated (TP, FP, FN, TN), and how our predicted value compared to the actual value in a confusion matrix. Let’s decipher the matrix: The target variable has two values: Positive or Negative The columns represent the actual values of the target variable The rows represent the predicted values of the target variable True Positive, True Negative, False Positive and False Negative in a Confusion Matrix. True Positive (TP) The predicted value matches the actual value The actual value was positive and the model predicted a positive value True Negative (TN) The predicted value matches the actual value The actual value was negative and the model predicted a negative value False Positive (FP) – Type 1 error The predicted value was falsely predicted The actual value was negative but the model predicted a positive value Also known as the Type 1 error False Negative (FN) – Type 2 error The predicted value was falsely predicted The actual value was positive but the model predicted a negative value also known as the Type 2 error Example: Case: Loan (Good loan & Bad loan) The result of TP will be that bad loans are correctly predicted as bad loans. The result of TN will be that good loans are correctly predicted as good loans. The result of FP will be that (actual) good loans are incorrectly predicted as bad loans. The result of FN will be that (actual) bad loans are incorrectly predicted as good loans. The banks would lose a bunch of money if the actual bad loans are predicted as good loans due to loans not being repaid. On the other hand, banks won't be able to make more revenue if the actual good loans are predicted as bad loans. Therefore, the cost of False Negatives is much higher than the cost of False Positives.

Related questions

0 votes
    Calculate Accuracy, Precision, Recall and F1 Score for the following Confusion Matrix on Heart Attack Risk. Also suggest ... and why? Select the correct answer from above options...
asked Nov 12, 2021 in Education by JackTerrance
0 votes
    Explain in detail the inter-relationship between the food chain and food web. Select the correct ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    We have studied the air pollution, water pollution and soil pollution in detail in earlier classes. ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 8, 2021 in Education by JackTerrance
0 votes
    What would you do to help maintain the equilibrium in the various bio-geochemical cycles? Explain ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    You can create a scatter plot matrix using the __________ method in pandas.tools.plotting. (a) sca_matrix (b ... and answers pdf, Data Science interview questions for beginners...
asked Oct 28, 2021 in Education by JackTerrance
0 votes
    Model based prediction considers relatively easy version for covariance matrix. (a) True (b) False I have been ... and answers pdf, Data Science interview questions for beginners...
asked Oct 28, 2021 in Education by JackTerrance
0 votes
    Reproduce with the help of spores formed along the back or posterior surface of their leaves. (a) ... ,Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 8, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Bath ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Grasshopper. ... proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Rohu. ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Penguin. ... proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Frog. ... Science proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Lizard. ... proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Elephant. ... proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
0 votes
    Write the characters of each of the following animals with the help of classification chart: Jellyfish. ... proposed by,electromagnetic theory engineering physics,Science nptel...
asked Nov 7, 2021 in Education by JackTerrance
...