Reasoning:
Part 8.1
Accuracy tells how correct a set is. It measures true positives and true negatives:
A = \frac{TP + TN}{TP + FP + TN + FN},
which is just a lot of jargon for \frac{45+40}{100} = \boxed{0.85}
Part 8.2
Precision is used when the cost of false positive is high, such as in spam detection.
Positive Class Precision gives how correct the model was when dealing with positive data:
PCP = \frac{TP}{TP + FP } = \frac{45}{55} = 0.\bar{81}\approx 0.818
How many of the flagged positive were actually positive?
Negative Class Precision gives how correct the model was when dealing with normal, negative data.
NCP = \frac{TN}{TN+FN} = \frac{40}{45} = 0.\bar{8} \approx 0.889
Of the flagged negative, how many were actually negative?
Part 8.3
Recall scores are used when the cost of a false negative is high, such as in medical diagnoses.
PCR (Positive Class Recall) is used to identify:
Off all the true positives, how many did the model correctly identify?
PCR = \frac{TP}{TP+FN}
Notice how TP + FN gives the correct amount of true positives in the beginning.
PCR = \frac{45}{45+5} = \frac{9}{10} = 0.9
NCR (Negative Class Recall) = \frac{TN}{TN+FP} = \frac{40}{40 + 10} = 0.8
Of all the true negatives, how many were flagged?
Part 8.4
An F-1 score is a mix of the recall score and precision, more precisely the harmonic mean.
It is a good balancing mix, and is only high when both precision and recall are high.
F_1 = 2 * \frac{RP}{R+P}
Using this formula:
Positive F_1 = 2 * \frac{9/10 * 45 / 55}{9/10 + 45/55} \approx 0.857
Negative F_1 = 2 * \frac{8/9 * 4/5}{8/9 + 4/5} \approx 0.842
A quick sumary table of all the different scores:
Accuracy: Overall correct divided by Overall
Precision: Minimizing false positives
Recall: Minimizing false negatives
F_1: Mix of Precision and Recall