lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Amr ElAdawy <>
Subject Search Score percentage, Should not be relative to the highest score
Date Mon, 03 Jan 2011 07:15:39 GMT

Dear All,

                When using lucene to search documents, the results have a
score based on their relativity to the search term. Inside lucene, the score 
percentage is calculated as a percentage of the maximum score achieved.

Assume we are searching for Amr ElAdawy

We get results like the following along with the score:
Omar ElAdawy --> 1.6
Amro ElAdawy --> 1.9
Amir Adawi --> 1.3

With no exact match. Then the percentage will be calculated relative to the
highest score ( despite the fact that it is not exact match). So the
percentage will be:

Omar ElAdawy --> 84.21%
Amro ElAdawy --> 100%
Amir Adawi --> 68.42%

I need to change that, so the percentage will be relative to the exact match
score. And will be something like that (assuming the Matching result score
is 3):

Omar ElAdawy --> 53.33%
Amro ElAdawy --> 63.33%
Amir Adawi --> 43.33%

using lucene 2.9.4

Amr ElAdawy

View this message in context:
Sent from the Lucene - Java Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message