daenuprobst / covid19-cases-switzerland Goto Github PK
View Code? Open in Web Editor NEWData from BAG Tweets made useful.
Data from BAG Tweets made useful.
In the README.md file NW is linked to the cantonal page of OW. The correct link would be: https://www.nw.ch/gesundheitsamtdienste/6044
Anbei noch der erste Todesfall, bestätigt via:
https://www.sz.ch/public/upload/assets/45743/MM_Todesfall_26_3_2020.pdf
Auf der Seite:
https://www.sz.ch/behoerden/information-medien/medienmitteilungen/coronavirus.html/72-416-412-1379-6948
Due to the lack of test capacity, the case numbers are of limited value.
The number of fatalities would be a better representation of the extent of the pandemic.
Thanks.
First of all congrats for the well work done.
I just wanted to warn you that VD has one day of delay publishing data.
Data from yesterday has been published some hours ago but hasn't been tracked.
WBR. David.
Hi,
How can I contribute with additional data esp. historical data before the 6. march?
Made a small search for Basel-Stadt, and found the history of their cases back to the 27. February when the first case in BS was published
Es wäre auch gut, wenn die Daten in diesem Format (gleich wie Italien und China) aufbereitet werden:
Pro Tag eine Zeile für alle Kantone
https://github.com/zdavatz/covid19_ch/blob/master/data-cantons-csv/dd-covid19-ch-cantons-20200318-example.csv
Pro Tag eine Zeile für die ganze Schweiz.
https://github.com/zdavatz/covid19_ch/blob/master/data-switzerland-csv/dd-covid19-ch-switzerland-20200318-example.csv
https://gesundheit.lu.ch/themen/Humanmedizin/Infektionskrankheiten/Coronavirus
Thank you for your efforts!
Hi Dänu,
wäre es möglich die covid19_cases_switzerland.xlsx und covid19_cases_switzerland.csv auch zu updaten? mein Skript welches ein Modell fittet funktioniert damit :-)
Is it possible to retrive and add data on hospitalized patients and patients needing therapy on ICU? Maybe from cantonal doctors?
First things first: Excellent work – keep it up!
Some of the charts are quite misleading, when – e.g. early in the day – many cantons have not yet published data.
Off the top of my head, I see two strategies:
(1) Make it very clear that the latest column/point is not representative (e.g. showing it semi-transparently or dashed, adding a comment like "3 out of 26 cantons" – whatever might help)
(2) When calculating totals, use the most recently available number, i.e. use data from the day before if no current number is available yet. This would at least not give the wrong impression that numbers are going down
Hello again !
I wonder how you enrich your dataset currently, do you do it by hand ? Would it help to set up small web crawlers that try to automatically fetch data in the listed websites and format it as desired ?
I could work on that if it's of any interest to you.
Kannst du die Todesfälle entweder kumulativ machen oder täglich (an dem Tag). Zur Zeit ist es eine Mischung und das ist verwirrend.
Wenn Todesfälle an einem Tag von einem Kanton nicht kommuniziert werden, dann einfach die Zahl des Vortages verwenden.
Minor suggestion:
It would be nice to have the top "Total Cases", "New Cases Today" and "Total Fatalities" also change to the numbers of the day when you change the slider to a certain date.
Total count of fatalities is too low.
Seems like the total fatalities do not match the reporting from each canton on the map and also the number seems lower than yesterday. Maybe one of the cantons is not included?
Zitat aus dem Interview im Blick "Ich bin ein Fan von Transparenz".
Dann bitte auf www.corona-data.ch deutlich sichtbar und im Klartext schreiben wer für die Seite verantwortlich ist und wie der Author kontaktiert werden kann (nicht alle haben/wollen Twitter...).
Bitte deutlich machen woher die Daten stammen. Ja ist zu finden, aber viel zu umständlich und alles andere als deutlich.
Warum eigentlich das ganze auf englisch? Wenn es um die Schweiz geht... Wir haben definitv andere Landessprachen. Englisch von mir aus aber bitte als Option.
Also, für Transparenz ist noch Raum nach oben!
Ansonsten, Top die Aufbereitung der Daten, Gratulation!
VD apparently changed its data from the 23rd onwards. According to the cantonal website given in the source the correct number for the 25th is only 2215 confirmed cases.
Thanks for the stats Cases per Canton (per 10,000 Inhabitants)! It helps put things into perspective.
You are probably already planning to add colors on the of map of cantons by number of cases.
As suggested by jakobzhao/virus#18 for hgis.uw.edu/virus, it would be nice to have colors scaled by population size. In Switzerland, a canton like Zürich has 100x more residents than Appenzell Innerrhoden.
When looking at the data for Zurich between 21.3 and 23.3 it seems there are no cases for two days and then there is a spike of 295 cases on the 23rd.
But looking at the data it is clear that on the 23 there were only 177 new cases. The problem arises from the missing data on the 21st.
For me there are two possible "correct" ways of displaying the data.
Vielleicht kann das in den Visualizer eingebaut werden:
# Data from https://www.corona-data.ch/
# ->
import numpy as np
import matplotlib.pyplot as plt
from scipy.optimize import curve_fit
dates=np.array(['2020-03-06', '2020-03-07', '2020-03-08', '2020-03-09', '2020-03-10', '2020-03-11', '2020-03-12', '2020-03-13', '2020-03-14', '2020-03-15', '2020-03-16', '2020-03-17', '2020-03-18', '2020-03-19', '2020-03-20', '2020-03-21'], dtype='datetime64')
x=np.array(len(dates))
x0 = dates.tolist()[0].day
x = [x.day - x0 + 1 for x in dates.tolist()]
y=np.array([207, 262, 331, 372, 490, 638, 851, 1122, 1357, 2155, 2327, 2650, 3513, 4804, 5675, 6239])
def exponenial_func(x, a, b, c):
return a*np.exp(-b*x)+c
def logistic_func(x, q, b, c):
K = 8_000_000 # Upper asymptote
v = 0.5 # affects near which asymptote maximum growth occurs
assert v > 0
return K / ((1 + q*np.exp(-b*x))**(1/v))
popt, pcov = curve_fit(logistic_func, x, y, p0=(1, 1e-6, 1))
xx=np.array(range(1, 120))
yy = [logistic_func(i, *popt) for i in xx]
yerr= [2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2]
xerr=[0.01,0.01,0.01,0.01,0.01,0.01,0.01,0.01, 0.01,0.01,0.01]
#plt.errorbar(x,y,yerr=yerr,xerr=xerr, fmt= '.')
plt.plot(x,y,'o', xx, yy)
plt.ylim (0,8e6)
#plt.plot(dates, y, 'o')
#plt.ylim (0,y[-1])
plt.xlabel ('Time')
plt.ylabel ('Cases')
plt.show()
Super gemacht und ich würde gerne wissen woher haben die Zahl von ZH? Ich finde im Seite nicht.
Thanks for your work !
It seems the data of https://dashcoch.herokuapp.com/ doesn't match the data of https://corona-ch.surge.sh/.
EG : 18.03.20, dashcoch : 193 for Bern, corona-ch : 226 for Bern
Any idea why ?
Thanks for making this!! It looks great.
A suggestion would be to merge the history plot and the predication plot. The predication maybe can be indicated with lighter color or dash line. I personally think it would be less redundant.
in the number of fatalities there is a problem. The number for canton TI the number is not for day but it's the cumulative sum of fatalities until that day.
i.e. 2020-03-23 TI fatalities 48 but should be 48-37
First of all a big thumbs up for your work! I myself was looking for daily numbers which is hard to find.
the sum of all cantons is the later the more different from CH.
e.g. 25.3.2020
sum of cantons: 8319
CH number: 10909
Where is this gap coming from?
Best Regards
Moritz
Besten Dank im voraus für diese grossartige Arbeit.
Immer mehr wird aktuell festgestellt, dass die Todeszahlen jeden Covid-19 positiv getesteten beinhalten. Nun werden immer mehr Stimmen laut mit dem Einwand, dass davon nicht wenige an Vorerkrankungen verstorben sind, die mit Covid-19 nicht zu begründen sind.
Bei den Todeszahlen wäre darum eine Version mit vier weiteren Eingabefeldern interessant mit Werten/Prozent:
Todesursache …
– eindeutig keine Covid-19 Ursache
– Kofaktor Covid-19 wahrscheinlich
– Kofaktor Covid-19 möglich
– Covid-19 bestätigt
Reported Cases:
Keine Symptome
Erkrankt
Schönen Sonnentag,
Urs
Ein kleines Feedback zu den Zahlen zum 18. März. Ich finde es suboptimal, die Inzidenzen vom BAG auf Fallzahlen hochzurechnen. Einerseits weil es seitens BAG kaum Metadaten dazu gibt (auf welchem Bev-Stand beruht es, was ist der jeweilige Datenstand in den Kantonen etc.) und weil ich finde, die Primärquelle des Kantons ist grundsätzlich immer besser und weniger zeitverzögert. Ich persönlich wäre froh, wenn nach wie vor nur Zahlen von den Kantonen verwendet würden, auch wenn es halt nicht jeden Tag neue gibt.
Danke auf jeden Fall an dich und deine MitstreiterInnen für den tollen Service.
Hello
Thank you for your work, which is very important. But I have one doubt:
You have a plot with the title "Prevalence per 10,000 Inhabitants". I'm not sure if you really mean "prevalence". Prevalance would be the total of the (infected persons at time)/population. Right now this is very similar to the cumulative incidence since not to many persons have recovered or died yet. I believe you actually report the cumulative incidence, which is the (cumulative case number at time)/(population at the beginning).
To be more clear why I believe this:
Italy had today 69176 confirmed cases (Johns Hopkins, 25.3).
Cumulative incidence per 10000: 69176/60262701*10000=11.48
At this time 8326 have recovered and 6820 have died.
The prevalence would therefore be around: 8.97.
You report for today: 11.44.
See here for a good introduction into the topic:
https://www.cdc.gov/csels/dsepd/ss1978/lesson3/section2.html
Hi,
thanks for sharing this !
In your exponential fit, I suggest to keep uncertainties into account, assuming they are Poissonian.
This is the code snippet
popt, pcov = curve_fit(exponential_func, x, y, p0=(1, -1e-6, 1), sigma=numpy.sqrt(y))
Best wishes,
Carlo
I was looking for Geneva cases historical data. There are in two files : covid19-cases-switzerland.csv and covid19-cases-switzerland-openzh.csv.
However, they disagree for the last data point (2020-03-26) : 1743 cases in the first, 1903 in the openzh one.
Do you know why ? Which one should I take ?
AlainD
All statistics have outliers. - Nenia Campbell, Terrorscape
There is currently a stat about new cases per Canton. In my opinion, a moving average trend line of total new cases per day would be very interesting.
With the current situation of the lockdown the assumption is, a trend line would show the results of these regulations. I median value is suggested because the data publishing is not coordinated and may vary much.
To show an example: https://plotly.com/~tongmanhok/4/simple-moving-averages/#plot
Columns "total_currently_positive_cases" and "deaths" have identical values. Can you please double-check? Thx!
"Fatalities per 10'000" is the single most important value in my opinion.
The criterion to test or not to test a person depend on the Canton, but a dead person is a dead person every where (I like to think, that at least in Switzerland statistics are not adjusted in order let the other believe that we are the best of the world).
To be put as radio button in the first Switzerland map (with the Cantonal data).
Hi, now BL also publishes its numbers daily here: https://github.com/openZH/covid_19/blob/master/COVID19_Fallzahlen_Kanton_BL_total.csv
Can you add them? Thanks for your precious work!
Hi,
ist es möglich dass auch die Daten in covid_cases_switzerland.csv mindestens ein paar mal in Tag aktualisiert werden? Ich habe ein Python-Skript, das diese Daten einliest und eine logistische funktion interpoliert.
Danke im Voraus!
Hello !
First thank you for your precious work !
I wonder why you don't seem to use data publish by bag on total number of cases here:
https://www.bag.admin.ch/bag/de/home/krankheiten/ausbrueche-epidemien-pandemien/aktuelle-ausbrueche-epidemien/novel-cov/situation-schweiz-und-international.html
We could download from this file that seems to be the source of tweets graphs :
https://www.bag.admin.ch/dam/bag/de/dokumente/mt/k-und-i/aktuelle-ausbrueche-pandemien/2019-nCoV/covid-19-datengrundlage-lagebericht.xlsx.download.xlsx/200325_Datengrundlage_Grafiken_COVID-19-Bericht.xlsx
I notice though that numbers are quite different from this dataset. But maybe it could act as minimum fallback or fill the historical gaps.
Tell me your opinion on that and if you're interested I could create a PR to have a script downloading it in your format !
In the dashboard, the Case Fatality Rate is shown as being "Cases / Fatalities" while it should be "Fatalities / Cases".
Some cantons publish data on recovered patients (such as BS). It would be useful to include this in some form.
Is there data on the current number of infected persons somewhere, as opposed to infection incidents?
opendataZH has collected values for all cantons in https://github.com/openZH/covid_19/blob/master/fallzahlen_kanton_total_csv/
Recently BAG also publish data on how many patients get tested. It seem to be only a rough estimate, but if compared to daily reported cases, it will show a change in infection rate among the tested sub population (patients at risk showing symptoms), or at least a change in behaviour woh is going to test himself.
It's a pity that the canton doesn't publish official numbers on https://www.fr.ch/de/covid19/gesundheit/covid-19/coronavirus-entwicklungen-der-situation anymore. Where does the current data come from?
I don't know if the number of cases is correct, but the number of fatalities is off. While the data in this repository shows 1 death, at least 4 deaths were reported by the local medias as of 2020-03-22 [La Liberté, Radio Fr].
I am using Firefox on Linux
Do you have data showing the age of people died? Would really help to decide on next steps.
Hi @daenuprobst,
Little tipo in one graph's title: Prelavence -> Prevalence.
Great work, keep on with this!
Lukas
Thanks for your work to help the people in need! Your site has been added! I currently maintain the Open-Source-COVID-19 page, which collects all open source projects related to COVID-19, including maps, data, news, api, analysis, medical and supply information, etc. Please share to anyone who might need the information in the list, or will possibly contribute to some of those projects. You are also welcome to recommend more projects.
http://open-source-covid-19.weileizeng.com/
Cheers!
Great site - thanks. It might be interesting to show some impact of social distancing. For example a projection of the number of days for the number of infections to double. I think the formula is simply ln(2)/ln(1+daily growth rate).
Just a thought.
Thx
Hi,
Thanks a lot for making this, it looks great.
I was wondering, mabye you could add the measures the goverment has taken at different time points in the various cantons.
I could provide a csv file with this data in case you like the idea.
Best,
Judith
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.