Skip to content

Commit

Permalink
fix adding missing excess deaths data
Browse files Browse the repository at this point in the history
  • Loading branch information
djay committed Jun 17, 2024
1 parent 220bfa1 commit 79e3ce7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion covid_data_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -845,7 +845,7 @@ def excess_deaths():
mcount += 1
logger.opt(raw=True).info("\n")
logger.info("Excess Deaths: Total in {}-{}: {}", year, month, mtotal)
df = df.combine_first(pd.DataFrame(rows, columns=index + ["Deaths"]).set_index(index))
df = pd.DataFrame(rows, columns=index + ["Deaths"]).set_index(index).combine_first(df)
if changed:
export(df, "deaths_all", csv_only=True, dir="inputs/json")
shutil.copy(os.path.join("inputs", "json", "deaths_all.csv"), "api") # "json" for caching, api so it's downloadable
Expand Down

1 comment on commit 79e3ce7

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.