dsychin / covid19brunei

Brunei COVID-19 Tracker
https://covid19brunei.com
MIT License
5 stars 3 forks source link

Suggestions #28

Open haziqj opened 4 years ago

haziqj commented 4 years ago

Nice work guys. Data is manual entry into the .csv file right?

Suggestions:

I could mockup some graphs to explain what I mean, but unfortunately I don't know JavaScript 😅

dsychin commented 4 years ago

Hi Haziq, thanks for your suggestions.

Chart the doubling time for the cases. In an outbreak, the growth rate is of particular interest. A small number of cases can grow rapidly in an exponential growth. I know how to get the doubling times using Excel, but not in .js I'm afraid.

Do you mean like a line that shows the average gradient? If not, a mockup graph would be helpful for me to see how it's supposed to look like.

I think the grey 'Increase' line is going to be eclipsed (hopefully) by the yellow 'Total' line, so reading the grey line is going to be a bit difficult as time goes on and possibly misleading as it may look flat. Growth factors would be nice to see too, defined by no. new cases at time t divided by no. new cases at time t-1.

I will keep that in mind.

haziqj commented 4 years ago

Doubling time essentially means how long did it take for the number of cases to double. For the data, I calculate

t Total Cases Doubling time (days)
1 1 NA
2 6 1
3 11 2
4 23 1
5 37 2
6 40 3
7 50 3
8 54 4

In Excel, it's essentially a VLOOKUP to see what t corresponds to half the current total cases. E.g. at time t = 7, total cases was 50, so at what t was the total cases 25--answer is roughly t = 4 (cases = 23), in which case the doubling time is 7 - 4 = 3.

Looking at gradients would implicitly assume a linear relationship I think, whereas the goal is to determine from the doubling time if the growth is exponential or not. If doubling time remains constant, then it is exponential growth. If it is increasing then it is slowing down, etc.