Confusion Matrix
What types of predictions is a Confusion Matrix used to measure?
Applies to discrete answers, like Classification models (not continuous values)
Confusion Matrix
What is the Accuracy of a model?
The % of predictions that are correct (true positive and true negative)
Confusion Matrix
What is the Precision of a model?
How well does a model predict
Confusion Matrix
What’s the ratio considered for Precision?
true positives vs. false positives
Confusion Matrix
Formula for Precision?
true positives / (true positives + false positives)
Not important
Confusion Matrix
What is invariant about Precision?
The model said ‘yes’, decide if it was right or not.
Confusion Matrix
What can you minimize by paying attention to Precision?
Minimize the number of false positives
Confusion Matrix
Example of when high Precision is important?
Saying the defendant is guilty
Confusion Matrix
What is the Recall of a model?
Does the model say ‘yes’ when it should say ‘yes’?
Confusion Matrix
What’s the ratio considered for Recall?
True positives vs. false negatives
Confusion Matrix
Formula for Recall?
True positives / (true positives + false negatives)
Not important
Confusion Matrix
What is the invariant about Recall?
The actual value is ‘yes’. What did the model say?
Confusion Matrix
What can you minimize by paying attention to Recall?
The number of false negatives (times the model should have said ‘yes’, but didn’t)
Confusion Matrix
Example of when high Recall is important?
Predicting if you have cancer
Confusion Matrix
How can you optimize a model for both Precision and Recall?
You can’t, try to balance the model based on your needs.
Confusion Matrix
How do you measure if your model is balanced?
“F1” is a metric that balances Precision and Recall when both are important.
Confusion Matrix
What’s the formula for F1?
F1 = (precition * recall * 2) / (precision + recall)
Not important
Confusion Matrix
What is Model Accuracy?
How well the model guesses correctly
Confusion Matrix
Quantitatively, what is Accuracy?
Amount of true positives and true negatives compared to all answers
Confusion Matrix
What metric is best when false positives are costly?
Precision
Confusion Matrix
What metric is best when false negatives are costly?
Recall
Errors in regression
What does MAE stand for?
Mean Absolute Error
Errors in regression
What is Mean Absolute Error?
Distance from data-point to regression line
Errors in regression
What does MAPE stand for?
Mean Absolute Percentage Error