Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
COVID-19-Data-Integration
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ivy Wang
COVID-19-Data-Integration
Commits
3c3113b3
Commit
3c3113b3
authored
2 years ago
by
Ivy Wang
Browse files
Options
Downloads
Patches
Plain Diff
fix daily Japan
parent
f35ee9e9
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
daily_data_scripts/daily_asia.py
+5
-5
5 additions, 5 deletions
daily_data_scripts/daily_asia.py
with
5 additions
and
5 deletions
daily_data_scripts/daily_asia.py
+
5
−
5
View file @
3c3113b3
...
...
@@ -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
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment