Total Pageviews

Thursday, 24 March 2011

True Negatives and Accuracy

Hello folks! Welcome back! We have talked about Precision and Recall and eventually three terminologies appeared: True positives, false positives and false negatives. Today, we will talk about accuracy and hence, we need to know another term: True negative.

Let's go back to our old example.

You were given 10 balls in a box, 6 of which are white and 4 are red. You were asked to pick only the red balls from the box and you picked 7 balls- 2 of them are really red but 5 white balls fooled you.

Now, our true positives are 2, false positives are 5 and false negatives are 2.

A true negative is what you thought negative and really was negative: in our case, which is- you thought a ball as white in the box, and that ball is really white. So, number of true negatives for our example is:

True negatives = Total Balls - (True positives + False Positives + False Negatives)
= 10 - (2 + 5 + 2) = 1.

Why are we eager to know the number of true negatives? Well, because if we want to measure how accurate you were in picking up red balls, then we need to know your true negatives as well.

The formula for accuracy is

Accuracy = (True positives + True negatives) / (True positives + True negatives + False positives + False negatives)

In your case, your accuracy is equal o (2 + 1) / 10 = 30%.

No comments:

Post a Comment