Supervised Learning Flashcards
Example Scenario: Email Spam Detection
Consider an email service provider implementing a spam detection system. The goal is to
emails as either “spam” or “not spam” (also known as “ham”).
Precision:
Precision measures the proportion of corectly identified spam emails out of all emails
by the model.
Formula: Precision = True Positives / (True Positives + False Positives)
True Positives (TP): The number of emails correctly classified as spam.
False Positives (FP): The number of non-spam emails incorrectly classified as
Precision Example: Let’s say the spam detection system flagged 100 emails as Sp
inspection
90 of them were actually spam (True Positives)
Precision = 90 /(90 + 10) = 90%
So
in this scenario
flagged as spam
90% of them were actually spam
Recall:
Recall measures the proportion of correctly identified spam emails out of all actual
dataset.
Formula: Recall =True Positives / (True Positives + False Negatives)
False Negatives (FN): The number of spam emails incorrectly classified as no
Recall Example: Suppose there were I 50 actual spam emails in the dataset. The spa
correctly identified 90 of them as spam (True Positives)
but it missed 60 spam emails
Recall = 90/(90 + 60) = 60%
In this case. the recall ofthe spam detection system is 60%. This indicates that out of all
the system managed to identify 60% of them correctly
but it missed 40%.
Interpretation:
• High Precision: Indicates that when the model preuicts an email as spam
it 19
correct. This reduces the chances of legitimate emails being incorrectly marke
crucial for user trust and satisfaction