Issue 17576

Search facet counts - round up LESS THAN value

Reporter: mraymond
Type: Improvement
Summary: Search facet counts - round up LESS THAN value
Priority: Major
Resolution: WontFix
Status: Closed
Created: 2015-05-07 15:13:40.583
Updated: 2017-10-10 10:50:35.967
Resolved: 2017-10-10 10:50:35.947
Description: On pages like this one the Higher Taxon filter on the right of the page shows numbers in brackets. When these are displayed as "<" it would make sense to then use numbers that are powers of 10. This would avoid strange things like lots of the groups showing "(<23,950).

This issue was noted by Donald.

*Reporter*: Melianie Raymond
*E-mail*: [mailto:mraymond]]]>

Comment: The reason we show the less symbol is because we do not know the exact count as it is creates to much load on the solr index to return all facets. We only list the largest 50 or hundred or so. So using a logarithmic scale does not help to remove the less symbol I am afraid.
Created: 2015-05-11 11:33:14.744
Updated: 2015-05-11 11:33:14.744

Comment: If I understand correctly, the issue is not the less-symbol but the over-precise number in conjunction with the "<" that makes it look a bit weird. If the list were to show "<25,000" instead of "<23,950", it would not really raise a question.
Created: 2015-05-11 11:56:41.915
Updated: 2015-05-11 11:56:59.518

Comment: What would the precision be we wannt to round to? To the power of 10 would be 100.000 in the case of 23,950, right?
Created: 2015-05-11 12:07:03.847
Updated: 2015-05-11 12:07:03.847

Created: 2015-05-11 13:46:16.969
Updated: 2015-05-11 13:46:16.969
say "less-than-value" (LTV) is the one currently displayed as "<23,408", and "next lowest counted value" (LCV) is the lowest value that still has been really counted, and "number of digits" (NOD) is the number of digits that LTV has, how about something that in messed-up Excel notation would look like

  roundup(LTV,NOD-1)  > LCV

i.e. round a LTV of 491 to 500 unless the next following LCV is <500 - then leave as is. One-digit numbers would not be changed (that is, "<3, 5, 7"), 112 would be rounded to 200, again only if the next number is not smaller than that, 23,417 would be rounded to 30,000 unless the next LCV is closer than that, in which case 23,417 would remain (unless we would then want to step to the next lower rounding level, but maybe that would be overdoing it?).

Would that work? Not powers of 10, but "devidable by 10 unless".

Created: 2015-05-11 14:01:55.439
Updated: 2015-05-11 14:01:55.439
how about rounding to this precision depending on the log10 of the LCV?
<1: no rounding, e.g. <7 stays <7
<2: round to 5, e.g. <27 becomes <30, <33 becomes <35
<3: round to 50, e.g. <127 becomes <150, <777 becomes <800
<4: round to 100, e.g. <1,127 becomes <1,200, <6,777 becomes <6,800
>4: round to 1000, e.g. <12,127 becomes <13,000, <177,333 becomes <178,000


Comment: Thanks - easier and more straightforward. Would work for me.
Created: 2015-05-11 14:04:38.307
Updated: 2015-05-11 14:04:38.307

Author: hoefft
Comment: this doesn't seem to apply to the new layout. please reopen if this is a misunderstanding on my part
Created: 2017-10-10 10:50:35.965
Updated: 2017-10-10 10:50:35.965