starting to add dateRange
This commit is contained in:
@@ -117,8 +117,8 @@ class BatchCodeTableInitializer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#displayBatchcodeByCountryBarChart(batchcode, barChartDescriptions, uiContainer) {
|
#displayBatchcodeByCountryBarChart(batchcode, barChartDescriptions, uiContainer) {
|
||||||
if (batchcode in barChartDescriptions) {
|
if (batchcode in barChartDescriptions.barChartDescriptions) {
|
||||||
const barChartDescription = barChartDescriptions[batchcode];
|
const barChartDescription = barChartDescriptions.barChartDescriptions[batchcode];
|
||||||
barChartDescription['batchcode'] = batchcode;
|
barChartDescription['batchcode'] = batchcode;
|
||||||
new BatchcodeByCountryBarChartView(uiContainer).displayBatchcodeByCountryBarChart(barChartDescription);
|
new BatchcodeByCountryBarChartView(uiContainer).displayBatchcodeByCountryBarChart(barChartDescription);
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -7,25 +7,24 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
|
"from CountryCountsByBatchcodeTable2BarChartDescriptionTableConverter import CountryCountsByBatchcodeTable2BarChartDescriptionTableConverter\n",
|
||||||
|
"from CountriesByBatchcodeProvider import getCountryCountsByBatchcodeTable, filterByBatchcodes\n",
|
||||||
|
"from Column2DataframeAdder import addColumn2Dataframe\n",
|
||||||
|
"from BatchCodeTableFactory import BatchCodeTableFactory\n",
|
||||||
|
"from HistogramFactoryAndPersister import createAndSaveGlobalHistograms\n",
|
||||||
|
"from SymptomByBatchcodeTableFactory import SymptomByBatchcodeTableFactory\n",
|
||||||
|
"from BatchCodeTablePersister import createGlobalBatchCodeTable\n",
|
||||||
|
"from BatchCodeTableHtmlUpdater import updateBatchCodeTableHtmlFile, saveLastUpdatedBatchCodeTable\n",
|
||||||
|
"from InternationalVaersCovid19Provider import getInternationalVaersCovid19, get_international_VAERSVAX_VAERSSYMPTOMS_Covid19\n",
|
||||||
|
"from DateProvider import DateProvider\n",
|
||||||
|
"from datetime import datetime\n",
|
||||||
|
"from VAERSFileDownloader import updateVAERSFiles\n",
|
||||||
|
"from IOUtils import IOUtils\n",
|
||||||
|
"import os\n",
|
||||||
"import pandas as pd\n",
|
"import pandas as pd\n",
|
||||||
"\n",
|
"\n",
|
||||||
"pd.set_option('display.max_rows', 100)\n",
|
"pd.set_option('display.max_rows', 100)\n",
|
||||||
"pd.set_option('display.max_columns', None)\n",
|
"pd.set_option('display.max_columns', None)\n"
|
||||||
"\n",
|
|
||||||
"import os\n",
|
|
||||||
"from IOUtils import IOUtils\n",
|
|
||||||
"from VAERSFileDownloader import updateVAERSFiles\n",
|
|
||||||
"from datetime import datetime\n",
|
|
||||||
"from DateProvider import DateProvider\n",
|
|
||||||
"from InternationalVaersCovid19Provider import getInternationalVaersCovid19, get_international_VAERSVAX_VAERSSYMPTOMS_Covid19\n",
|
|
||||||
"from BatchCodeTableHtmlUpdater import updateBatchCodeTableHtmlFile, saveLastUpdatedBatchCodeTable\n",
|
|
||||||
"from BatchCodeTablePersister import createGlobalBatchCodeTable\n",
|
|
||||||
"from SymptomByBatchcodeTableFactory import SymptomByBatchcodeTableFactory\n",
|
|
||||||
"from HistogramFactoryAndPersister import createAndSaveGlobalHistograms\n",
|
|
||||||
"from BatchCodeTableFactory import BatchCodeTableFactory\n",
|
|
||||||
"from Column2DataframeAdder import addColumn2Dataframe\n",
|
|
||||||
"from CountriesByBatchcodeProvider import getCountryCountsByBatchcodeTable, filterByBatchcodes\n",
|
|
||||||
"from CountryCountsByBatchcodeTable2BarChartDescriptionTableConverter import CountryCountsByBatchcodeTable2BarChartDescriptionTableConverter\n"
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -35,7 +34,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"print(datetime.now().strftime(\"%d.%m.%Y, %H:%M:%S Uhr\"))"
|
"print(datetime.now().strftime(\"%d.%m.%Y, %H:%M:%S Uhr\"))\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -49,7 +48,7 @@
|
|||||||
"print(' lastUpdated:', dateProvider.getLastUpdated())\n",
|
"print(' lastUpdated:', dateProvider.getLastUpdated())\n",
|
||||||
"print('lastUpdatedDataSource:', dateProvider.getLastUpdatedDataSource())\n",
|
"print('lastUpdatedDataSource:', dateProvider.getLastUpdatedDataSource())\n",
|
||||||
"needsUpdate = dateProvider.needsUpdate()\n",
|
"needsUpdate = dateProvider.needsUpdate()\n",
|
||||||
"print('needsUpdate:', needsUpdate)"
|
"print('needsUpdate:', needsUpdate)\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -59,7 +58,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"years_from_start_of_COVID_vaccination_to_present = list(range(2020, datetime.now().year + 1))"
|
"years_from_start_of_COVID_vaccination_to_present = list(range(2020, datetime.now().year + 1))\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -91,7 +90,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"international_VAERSVAX_Covid19"
|
"international_VAERSVAX_Covid19\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -101,7 +100,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"international_VAERSSYMPTOMS"
|
"international_VAERSSYMPTOMS\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -200,25 +199,44 @@
|
|||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": null,
|
||||||
"id": "8e1b471a",
|
"id": "7ebfd53c",
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"barChartDescriptionTable['BAR_CHART_DESCRIPTION'].to_json('../docs/data/barChartDescriptionTable.json')"
|
"def dateRange2Str(dateRange):\n",
|
||||||
|
" return {\n",
|
||||||
|
" 'start': _date2Str(dateRange[0]),\n",
|
||||||
|
" 'end': _date2Str(dateRange[1])\n",
|
||||||
|
" }\n",
|
||||||
|
"\n",
|
||||||
|
"def _date2Str(date):\n",
|
||||||
|
" return date.strftime(\"%d.%m.%Y\")"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": null,
|
||||||
"id": "af8b598c",
|
"id": "0ec101b6",
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"from GoogleAnalyticsReader import GoogleAnalyticsReader\n",
|
"from GoogleAnalyticsReader import GoogleAnalyticsReader\n",
|
||||||
"\n",
|
"\n",
|
||||||
"googleAnalyticsReader = GoogleAnalyticsReader(dataDir = 'data/GoogleAnalytics')\n",
|
"dateRange = GoogleAnalyticsReader(dataDir = 'data/GoogleAnalytics').getDateRange()\n",
|
||||||
"dateRange = googleAnalyticsReader.getDateRange()\n",
|
"barChartDescriptions = {\n",
|
||||||
"dateRange"
|
" 'dateRange': dateRange2Str(dateRange),\n",
|
||||||
|
" 'barChartDescriptions': barChartDescriptionTable['BAR_CHART_DESCRIPTION'].to_dict()\n",
|
||||||
|
"}\n"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"execution_count": null,
|
||||||
|
"id": "163830ba",
|
||||||
|
"metadata": {},
|
||||||
|
"outputs": [],
|
||||||
|
"source": [
|
||||||
|
"IOUtils.saveDictAsJson(barChartDescriptions, '../docs/data/barChartDescriptionTable.json')\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -350,7 +368,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"# vaccineDistributionByZipcode.to_excel('tmp/Amended-22-01962-Pfizer-2022-0426-pulled-2022-0823_sumDoses.xlsx')"
|
"# vaccineDistributionByZipcode.to_excel('tmp/Amended-22-01962-Pfizer-2022-0426-pulled-2022-0823_sumDoses.xlsx')\n"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user