Closed bhaden94 closed 3 years ago
Take in rate name and state/country name as parameters.
Find the average of that rate on the respective state/country. If no state/country given then find average of rate on all.
example return for incident_rate:
{ "incident_rate": 1107.56 }
The bar chart needs data like this:
[ { rate: 'Incident Rate', state_country: 0, us_world: 2568 }, { rate: 'Mortality Rate', state_country: 0, us_world: 2.14, } ]
This issue needs to handle both the rates component and the bar chart. There may need to be a few different endpoints made for it.
https://github.com/bhaden94/covid-19-tracker-v2-fe/issues/29
Complete FE code change along with the new API routes.
Take in rate name and state/country name as parameters.
Find the average of that rate on the respective state/country. If no state/country given then find average of rate on all.
example return for incident_rate:
The bar chart needs data like this:
This issue needs to handle both the rates component and the bar chart. There may need to be a few different endpoints made for it.