Skip to content
Snippets Groups Projects
Commit 3c3113b3 authored by Ivy Wang's avatar Ivy Wang
Browse files

fix daily Japan

parent f35ee9e9
No related branches found
No related tags found
No related merge requests found
......@@ -168,13 +168,13 @@ def update_japan():
japan_all = pd.merge(japan, japan_death, on=["Date"])
#get region_code for Japan city
c.execute("SELECT region_code, region_name from Regions Where country_code = 'JP'")
result = c.fetchall()
#get region_code for Japan city
japan_region = []
region_dict = {}
for i in range(0,len(result)):
japan_region.append([result[i][0], result[i][1] + "_x", result[i][1] + "_y"])
region_dict[result[i][1]] = result[i][0]
for col in japan.columns:
if col != "Date" and col != "ALL":
region_dict[col] = get_region_code(japan_code, col, c)
japan_region.append([region_dict[col], col + "_x", col + "_y"])
#insert region daily case data
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment