When you train several models over a dataset you need a way to compare the model performances and choose the one that best suites your needs.

As we will see there are different ways to compare the results and then pick the best one.

Let’s start with what scores we can get out of the training process. Assuming we are running a classification model with 2 possible outcomes, then the model performance can be summarised with 4 figures known as the confusion matrix.

These 4 figures are:

**TP – True positive rate**: The number of samples correctly marked as positive**TN – True negative rate**: The number of samples correctly marked as negative**FP – False positive rate**: The number of samples incorrectly marked as positive (aka type 1 error)**FN – False negative rate**: The number of samples incorrectly marked as negative (aka type 2 error)