Skip to content

Commit

Permalink
cambio path de file por url
Browse files Browse the repository at this point in the history
  • Loading branch information
vanedaza committed Apr 17, 2020
1 parent ee6d8b8 commit 2e8a5c9
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion arcovid19.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
# =============================================================================

import os
import io
import sys
import datetime as dt
import itertools as it
Expand All @@ -53,6 +54,8 @@

import diskcache as dcache

import requests


# =============================================================================
# CONSTANTS
Expand Down Expand Up @@ -407,7 +410,10 @@ def grate_full_period(
prov_name, prov_c = self.cstats.get_provincia_name_code(provincia)

# READ PROVINCES DATA
areapop = pd.read_csv('databases/arg_provs.dat')
CASES_URL_P = "https://raw.githubusercontent.com/ivco19/libs/master/databases/arg_provs.dat"
s = requests.get(CASES_URL_P).content
areapop = pd.read_csv(io.StringIO(s.decode('utf-8')))

p = areapop['pop'][areapop['key'] == prov_c].values[0]
norm_factor = 1.
if norm:
Expand Down

0 comments on commit 2e8a5c9

Please sign in to comment.