Dino wrote: > trying to do some dayaviz with Italian Covid Open Data ( > https://github.com/italia/covid19-opendata-vaccini/ ) > > here's how I pull my data: > ____________________________ > import sys > import urllib.request > import pandas as pd > import ssl > ssl._create_default_https_context = ssl._create_unverified_context > > URL = > "https://github.com/italia/covid19-opendata-vaccini/blob/master/dati/somministrazioni-vaccini-latest.csv?raw=true" > > with urllib.request.urlopen(URL) as url: > df = pd.read_csv(url) > ____________________________ > > One of my diagrams came out screwed up today, and I am having a hard > time understanding what went wrong: > > https://imgur.com/a/XTd4akn > > Any ideas? >
I first downloaded a local copy of the .csv file using .... wget URL Then the python code below following the plot parameters shown in your imgur.com image which was executed in a jupyter notebook .... # it_covid.py ----------------------------------------------- import pandas as pd import seaborn as sns import numpy as np import matplotlib.pyplot as plt df = pd.read_csv( 'data/somministrazioni-vaccini-latest.csv' ) plt.figure( figsize = ( 20 , 10 ) ) plt.xticks( rotation = 70 ) sns.lineplot( x = "data_somministrazione" , y = "prima_dose" , data = df , hue = "nome_area" , ci = None ) plt.show() # ----------------------------------------------------------- The resulting plot doesn't seem to be cluttered as the one that you posted .... http://csphx.net/image/it_covid.png -- Stanley C. Kitching Human Being Phoenix, Arizona -- https://mail.python.org/mailman/listinfo/python-list