Covid-19: Comparison of Czech and German regions.
I joined several Czech regions to make them of similar size as the German states.
<VirtualHost *:80> | |
# example of settings for Postgrest API | |
ServerAdmin admin@example.com | |
ServerName api.example.com | |
ProxyPreserveHost On | |
# setup the proxy | |
<Proxy *> | |
Order allow,deny | |
Allow from all |
"""Create testing files for calcs.""" | |
# import gspread | |
import json | |
import pandas as pd | |
import random | |
import string | |
path = "calc/" | |
path1 = path + "kalkulacka/" |
{"bn": {"population": "408786", "region": "Asia", "id": "bn", "name": "Brunei Darussalam", "sub-region": "South-Eastern Asia", "latitude": "4.5", "longitude": "114.666666667", "code": "bn"}, "us": {"population": "313847465", "region": "Americas", "id": "us", "name": "United States", "sub-region": "Northern America", "latitude": "38", "longitude": "-97", "code": "us"}, "cx": {"population": "1496", "region": "", "id": "cx", "name": "Christmas Island", "sub-region": "", "latitude": "-10.5", "longitude": "105.666666667", "code": "cx"}, "li": {"population": "36713", "region": "Europe", "id": "li", "name": "Liechtenstein", "sub-region": "Western Europe", "latitude": "47.2666666667", "longitude": "9.5333333333", "code": "li"}, "la": {"population": "6586266", "region": "Asia", "id": "la", "name": "Lao People's Democratic Republic", "sub-region": "South-Eastern Asia", "latitude": "18", "longitude": "105", "code": "la"}, "pn": {"population": "48", "region": "Oceania", "id": "pn", "name": "Pitcairn", "sub-region": "Poly |
# calculates optimal numbers of representives for hemicycle chart | |
import math | |
import csv | |
import numpy as np | |
import timeit | |
start = timeit.default_timer() | |
#benchmark: | |
#n0 = 200 : 4:23s, 5:52s, 6:132s, 7:285s, 8:579s, 9:1167s , 10:2342s, 11: 4632s |
<div> | |
<script type="text/javascript">window.PlotlyConfig = {MathJaxConfig: 'local'};</script> | |
<script src="https://cdn.plot.ly/plotly-latest.min.js"></script> | |
<div id="52dc101e-066a-4cb9-bd22-9445f42a0556" class="plotly-graph-div" style="height:500px; width:100%;"></div> | |
<script type="text/javascript"> | |
window.PLOTLYENV=window.PLOTLYENV || {}; | |
if (document.getElementById("52dc101e-066a-4cb9-bd22-9445f42a0556")) { |
Covid-19: Comparison of Czech and German regions.
I joined several Czech regions to make them of similar size as the German states.
// d3.tip | |
// Copyright (c) 2013 Justin Palmer | |
// | |
// Tooltips for d3.js SVG visualizations | |
(function (root, factory) { | |
if (typeof define === 'function' && define.amd) { | |
// AMD. Register as an anonymous module with d3 as a dependency. | |
define(['d3'], factory) | |
} else { |