Skip to content

Instantly share code, notes, and snippets.

@mikkokotila
Last active October 24, 2020 14:00
Show Gist options
  • Save mikkokotila/1bab977636dc8ff1d0d8e7d0cf967445 to your computer and use it in GitHub Desktop.
Save mikkokotila/1bab977636dc8ff1d0d8e7d0cf967445 to your computer and use it in GitHub Desktop.
import datetime, coronacaster, pandas
data = coronacaster.get_data_from_eu()
out = []
countries = data.countries
for country in countries:
# parameters start
for ftype in ['poly1', 'poly2', 'poly3', 'logis', 'sigmoid', 'scurve']:
for chain in [20]:
for sample in [10000]:
for tune in [2000]:
# do the thing
temp = coronacaster.forecast(country,
data,
ftype=ftype,
targetdate=datetime.date(2020, 11, 14), cpu_cores=16)
# make record of the thing
out.append(temp[0].values)
# save everything
pandas.DataFrame(out).to_csv('experiment-results.csv')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment