tgoop.com/pythonicAI/1062
Last Update:
Andriy Burkov, ML at Gartner, author of The Hundred-Page Machine Learning book:
People dealing with machine learning models are frequently confusing accuracy, precision, and recall.
Accuracy is the ratio of correct predictions in all examples used for testing. So, you tested your model on 100 examples (some of them are positives, some are negatives, the ratio doesn't matter). The model correctly predicted the label of 97 examples of those 100, so your accuracy is 97/100 = 0.97.
Precision is a measure of accuracy on the labels of interest only. Often, the labels of interest are positive labels (i.e., spam), but it depends on the application. So, you tested your model on 100 examples. The model predicted as spam 80 of them, but only 60 of those 80 were correct predictions, so your precision is 60/80 = 0.75.
Recall is a measure of how many examples of interest your model has identified as such. Let's say you have 100 examples, you know that 70 of them are spam. Your model only predicted as spam 60 of those 70. So your recall is 60/70 = 0.86.
Accuracy and precision are easy to confuse, but they represent totally different quantities, so be careful when you use these terms in conversations and reports.
Precision and recall usually have a relationship of being mutually exclusive. When you try to increase precision, you decrease recall and vice versa.
#machinelearning #artificialintelligence
@pythonicAi
BY Pythonic AI
Share with your friend now:
tgoop.com/pythonicAI/1062