Closed tonyfujs closed 3 years ago
I checked the current implementation of the country profile. It relies on the following endpoints:
Algorithm for country selection: In order to avoid display issues due to having too many countries on the chart, the following rule will be applied. If the number of countries in the region of the selected country is > 12, then the countries to be displayed will be selected as follow: o Selected country o 3 countries with lowest poverty rate in the region o 3 countries with highest poverty rate in the region o 2 countries with closest poverty rates to selected country and inferior to poverty rate of selected country o 2 countries with closest poverty rates to selected country and superior to poverty rate of selected country
Update algorithm: IF selected country does not pertain to top 5 or bottom 5, display: Selected country 3 countries with lowest poverty rate in the region 3 countries with highest poverty rate in the region 2 countries with closest poverty rates to selected country and inferior to poverty rate of selected country 2 countries with closest poverty rates to selected country and superior to poverty rate of selected country ELSE IF selected country pertains to top 5, display: top 6 countries bottom 5 countries ELSE display bottom 6 countries top 5 countries The country names will still change due to dynamic ranking, but the number of displayed countries will stay the same.
see: TFS issue 6478
This one is to be broken down into multiple issues. One for each endpoint:
Happy to change the endpoints names...
Let's tackle #36 , #34 , and #35 first, and then come back to this one.