coronavirus-dashboard-api-python-sdk icon indicating copy to clipboard operation
coronavirus-dashboard-api-python-sdk copied to clipboard

Typing/Documentation of cumDeaths28DaysByDeathDate

Open timcoote opened this issue 4 years ago • 0 comments

The metric 'cumDeaths28DaysByDeathDate' reads like it is a monotonically increasing value. However, the last value can be NaN, which arguably ought not to be possible.

If it is intended to return NaNs in the dataset, then the documentation ought, I think, to point this out as pandas has some default handling of NaNs, which will create confusion (typically they are treated as 0 in some aggregations, thus making the data element non-monotonic).

Otherwise, if 'cumDeaths28DaysByDeathDate' is a calculated value (it is the sum of 'newDeaths28DaysByDeathDate'), then the returned value ought to be the same as the previous day's value, rather than NaN.

timcoote avatar Jul 28 '21 08:07 timcoote