Don't quite understand your math. India 50%? Depending on what you are
after, it should either be 5/20 or 5/8. I can understand your problem
better if you can explain how those percentages are calculated.
In your first example, you have the percentage for Yahoo vs.
everything else. In your second example, you should percentages for
multiple values: India, US, and UK. Which one do you want? First one
is tricky, I would probably use two facets, one with a filter, and the
other one without, and then calculate percentages on the client side.
On Tue, Sep 11, 2012 at 1:55 AM, Vineeth Mohan
That is also a useful variable but what i mean was not that.
Lets say there are total of 30 feeds in an index and for the field Country ,
there are 10 India , 5 US and 3 UK.
No for the query "growth" , i got 20 hits , out of which for the field
country there are 5 India , 2 US and 1 UK.
What i want is for the facet Country:India , i want the result as India -
50% , US = 40% , UK = 33.3%
On Tue, Sep 11, 2012 at 2:02 PM, Lukáš Vlček email@example.com wrote:
you can easily calculate the value from hits.total and count of particular
On Tue, Sep 11, 2012 at 10:15 AM, Vineeth Mohan
Is there any way i can find the percentage of facet name matched for a
query rather than the number of documents having that facet.
That is , instead of telling that there are 1000 documents which have a
facet yahoo , i want the result which tells me that there are 60% document
which matches the query and have a facet yahoo. Rest 40% of documents which
have the facet yahoo dont match the query.