Precision, Recall and the F-measure

February 17th, 2009 by Carl | Filed under Algorithms, Search Engine Results, Search Engines.

venn-diagram-documents

The success of a search engine algorithm lies in its ability to retrieving information for a given query. There are two ways in which one might consider the return of results to be successful. Either you can obtain very accurate results or you can find many results which have some connection with the search query. In information retrieval, these are termed precision and recall, respectively.

The precision is defined as the fraction of retrieved documents that are relevant. Recall is defined as the fraction of relevant documents that are retrieved.This might seem like the distinction between the Judian People’s Front and the People’s Front of Judia but that is the definition.

It makes more sense, to consider the search results as table in which results can be retrieved or not and they can be relevant or not-relevant.

Relevant Not-Relevant
Retrieved true positive (tp) true negative(tn)
Not-Retrieved false negative (fn) false positive (fp)

In these terms the precision P and recall R are defined,

P = tp/{(tp+fp)}

R=tp/{(tp+fn)}

We can also define the accuracy as

A = {(tp+tn)}/{(tp+tn+fp+fn)}

There is a trade-off between precision and recall. Greater precision decreases recall and greater recall leads to decreased precision. TheĀ  F-measure is the harmonic-mean of P and R andĀ  takes account of both measures

F = 2/{{1/P}+{1/R}}={2PR}/(P+R) = {2tp}/{(2tp+fn+fp)}

Extra Products or Services That May Help
Do you need doll house accessories
Oak Dining table and chairs ! See our colelletcion!
Forklift available here
Bookmark and Share

Tags: , , , , ,

Share Your Thoughts

// //]]>