concept confusion matrix in category big data

appears as: confusion matrix, The confusion matrix, A confusion matrix
Introducing Data Science: Big data, machine learning, and more, using Python tools

This is an excerpt from Manning's book Introducing Data Science: Big data, machine learning, and more, using Python tools.

Now we can use the prediction and compare it to the real thing using a confusion matrix.

A confusion matrix is a matrix showing how wrongly (or correctly) a model predicted, how much it got “confused.” In its simplest form it will be a 2x2 table for models that try to classify observations as being A or B. Let’s say we have a classification model that predicts whether somebody will buy our newest product: deep-fried cherry pudding. We can either predict: “Yes, this person will buy” or “No, this customer won’t buy.” Once we make our prediction for 100 people we can compare this to their actual behavior, showing us how many times we got it right. An example is shown in table 3.1.