Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save seanjtaylor/39c9297c8af5bf82b2fd2df4c05de8ab to your computer and use it in GitHub Desktop.
Save seanjtaylor/39c9297c8af5bf82b2fd2df4c05de8ab to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"/Users/seant/src/ergo/ergo/ppl.py:15: TqdmExperimentalWarning: Using `tqdm.autonotebook.tqdm` in notebook mode. Use `tqdm.tqdm` instead to force console mode (e.g. in jupyter console)\n",
" from tqdm.autonotebook import tqdm\n"
]
}
],
"source": [
"from datetime import date\n",
"import getpass\n",
"\n",
"import altair as alt\n",
"from ergo import Metaculus\n",
"import pandas as pd"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 2;\n",
" var nbb_unformatted_code = \"%load_ext nb_black\";\n",
" var nbb_formatted_code = \"%load_ext nb_black\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"%load_ext nb_black"
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"sjt\n",
"········\n"
]
},
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 3;\n",
" var nbb_unformatted_code = \"metaculus = Metaculus(\\n username=input(), password=getpass.getpass(), api_domain=\\\"pandemic\\\"\\n)\";\n",
" var nbb_formatted_code = \"metaculus = Metaculus(\\n username=input(), password=getpass.getpass(), api_domain=\\\"pandemic\\\"\\n)\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"metaculus = Metaculus(\n",
" username=input(), password=getpass.getpass(), api_domain=\"pandemic\"\n",
")"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 4;\n",
" var nbb_unformatted_code = \"sf_questions = {\\n date(2020, 6, 30): metaculus.get_question(4571),\\n date(2020, 7, 31): metaculus.get_question(4572),\\n date(2020, 8, 31): metaculus.get_question(4573),\\n date(2020, 9, 30): metaculus.get_question(4574),\\n}\";\n",
" var nbb_formatted_code = \"sf_questions = {\\n date(2020, 6, 30): metaculus.get_question(4571),\\n date(2020, 7, 31): metaculus.get_question(4572),\\n date(2020, 8, 31): metaculus.get_question(4573),\\n date(2020, 9, 30): metaculus.get_question(4574),\\n}\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"sf_questions = {\n",
" date(2020, 6, 30): metaculus.get_question(4571),\n",
" date(2020, 7, 31): metaculus.get_question(4572),\n",
" date(2020, 8, 31): metaculus.get_question(4573),\n",
" date(2020, 9, 30): metaculus.get_question(4574),\n",
"}"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 6;\n",
" var nbb_unformatted_code = \"sf_predictions = pd.DataFrame(\\n [\\n (\\n ds,\\n q.community_dist().percentiles([0.25])[0].max,\\n q.community_dist().percentiles([0.5])[0].max,\\n q.community_dist().percentiles([0.75])[0].max,\\n )\\n for ds, q in sf_questions.items()\\n ],\\n columns=[\\\"ds\\\", \\\"lcl\\\", \\\"med\\\", \\\"ucl\\\"],\\n).assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\";\n",
" var nbb_formatted_code = \"sf_predictions = pd.DataFrame(\\n [\\n (\\n ds,\\n q.community_dist().percentiles([0.25])[0].max,\\n q.community_dist().percentiles([0.5])[0].max,\\n q.community_dist().percentiles([0.75])[0].max,\\n )\\n for ds, q in sf_questions.items()\\n ],\\n columns=[\\\"ds\\\", \\\"lcl\\\", \\\"med\\\", \\\"ucl\\\"],\\n).assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"sf_predictions = pd.DataFrame(\n",
" [\n",
" (\n",
" ds,\n",
" q.community_dist().percentiles([0.25])[0].max,\n",
" q.community_dist().percentiles([0.5])[0].max,\n",
" q.community_dist().percentiles([0.75])[0].max,\n",
" )\n",
" for ds, q in sf_questions.items()\n",
" ],\n",
" columns=[\"ds\", \"lcl\", \"med\", \"ucl\"],\n",
").assign(ds=lambda x: pd.to_datetime(x[\"ds\"]))"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 7;\n",
" var nbb_unformatted_code = \"df = pd.read_csv(\\n \\\"https://covid19-static.cdn-apple.com/covid19-mobility-data/2009HotfixDev25/v3/en-us/applemobilitytrends-2020-06-07.csv\\\"\\n)\";\n",
" var nbb_formatted_code = \"df = pd.read_csv(\\n \\\"https://covid19-static.cdn-apple.com/covid19-mobility-data/2009HotfixDev25/v3/en-us/applemobilitytrends-2020-06-07.csv\\\"\\n)\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"df = pd.read_csv(\n",
" \"https://covid19-static.cdn-apple.com/covid19-mobility-data/2009HotfixDev25/v3/en-us/applemobilitytrends-2020-06-07.csv\"\n",
")"
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"\n",
"<div id=\"altair-viz-8666915bc3934d1a9048f0f53322d2a7\"></div>\n",
"<script type=\"text/javascript\">\n",
" (function(spec, embedOpt){\n",
" let outputDiv = document.currentScript.previousElementSibling;\n",
" if (outputDiv.id !== \"altair-viz-8666915bc3934d1a9048f0f53322d2a7\") {\n",
" outputDiv = document.getElementById(\"altair-viz-8666915bc3934d1a9048f0f53322d2a7\");\n",
" }\n",
" const paths = {\n",
" \"vega\": \"https://cdn.jsdelivr.net/npm//vega@5?noext\",\n",
" \"vega-lib\": \"https://cdn.jsdelivr.net/npm//vega-lib?noext\",\n",
" \"vega-lite\": \"https://cdn.jsdelivr.net/npm//vega-lite@4.8.1?noext\",\n",
" \"vega-embed\": \"https://cdn.jsdelivr.net/npm//vega-embed@6?noext\",\n",
" };\n",
"\n",
" function loadScript(lib) {\n",
" return new Promise(function(resolve, reject) {\n",
" var s = document.createElement('script');\n",
" s.src = paths[lib];\n",
" s.async = true;\n",
" s.onload = () => resolve(paths[lib]);\n",
" s.onerror = () => reject(`Error loading script: ${paths[lib]}`);\n",
" document.getElementsByTagName(\"head\")[0].appendChild(s);\n",
" });\n",
" }\n",
"\n",
" function showError(err) {\n",
" outputDiv.innerHTML = `<div class=\"error\" style=\"color:red;\">${err}</div>`;\n",
" throw err;\n",
" }\n",
"\n",
" function displayChart(vegaEmbed) {\n",
" vegaEmbed(outputDiv, spec, embedOpt)\n",
" .catch(err => showError(`Javascript Error: ${err.message}<br>This usually means there's a typo in your chart specification. See the javascript console for the full traceback.`));\n",
" }\n",
"\n",
" if(typeof define === \"function\" && define.amd) {\n",
" requirejs.config({paths});\n",
" require([\"vega-embed\"], displayChart, err => showError(`Error loading script: ${err.message}`));\n",
" } else if (typeof vegaEmbed === \"function\") {\n",
" displayChart(vegaEmbed);\n",
" } else {\n",
" loadScript(\"vega\")\n",
" .then(() => loadScript(\"vega-lite\"))\n",
" .then(() => loadScript(\"vega-embed\"))\n",
" .catch(showError)\n",
" .then(() => displayChart(vegaEmbed));\n",
" }\n",
" })({\"config\": {\"view\": {\"continuousWidth\": 400, \"continuousHeight\": 300}}, \"layer\": [{\"data\": {\"name\": \"data-124e215f3b099dc03b2fc9646a3f129a\"}, \"mark\": \"line\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"value\"}}, \"title\": \"SF Transit\"}, {\"data\": {\"name\": \"data-ba117893aec2e1fef8e03e1cf0baa4df\"}, \"mark\": \"point\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"med\"}}}, {\"data\": {\"name\": \"data-ba117893aec2e1fef8e03e1cf0baa4df\"}, \"mark\": \"errorbar\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"lcl\"}, \"y2\": {\"field\": \"ucl\"}}}], \"$schema\": \"https://vega.github.io/schema/vega-lite/v4.8.1.json\", \"datasets\": {\"data-124e215f3b099dc03b2fc9646a3f129a\": [{\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-13T00:00:00\", \"value\": 100.0}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-14T00:00:00\", \"value\": 101.59}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-15T00:00:00\", \"value\": 104.05}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-16T00:00:00\", \"value\": 97.69}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-17T00:00:00\", \"value\": 115.19}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-18T00:00:00\", \"value\": 108.1}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-19T00:00:00\", \"value\": 92.83}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-20T00:00:00\", \"value\": 98.47}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-21T00:00:00\", \"value\": 108.29}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-22T00:00:00\", \"value\": 114.0}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-23T00:00:00\", \"value\": 113.35}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-24T00:00:00\", \"value\": 122.65}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-25T00:00:00\", \"value\": 112.84}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-26T00:00:00\", \"value\": 90.13}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-27T00:00:00\", \"value\": 107.83}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-28T00:00:00\", \"value\": 104.67}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-29T00:00:00\", \"value\": 108.54}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-30T00:00:00\", \"value\": 110.47}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-01-31T00:00:00\", \"value\": 122.26}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-01T00:00:00\", \"value\": 111.39}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-02T00:00:00\", \"value\": 87.44}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-03T00:00:00\", \"value\": 103.25}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-04T00:00:00\", \"value\": 106.6}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-05T00:00:00\", \"value\": 108.83}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-06T00:00:00\", \"value\": 112.99}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-07T00:00:00\", \"value\": 125.9}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-08T00:00:00\", \"value\": 121.33}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-09T00:00:00\", \"value\": 90.89}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-10T00:00:00\", \"value\": 108.49}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-11T00:00:00\", \"value\": 111.13}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-12T00:00:00\", \"value\": 112.76}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-13T00:00:00\", \"value\": 115.84}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-14T00:00:00\", \"value\": 129.3}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-15T00:00:00\", \"value\": 116.41}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-16T00:00:00\", \"value\": 99.89}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-17T00:00:00\", \"value\": 101.12}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-18T00:00:00\", \"value\": 111.35}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-19T00:00:00\", \"value\": 113.44}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-20T00:00:00\", \"value\": 116.27}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-21T00:00:00\", \"value\": 129.56}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-22T00:00:00\", \"value\": 120.02}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-23T00:00:00\", \"value\": 98.3}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-24T00:00:00\", \"value\": 108.15}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-25T00:00:00\", \"value\": 109.17}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-26T00:00:00\", \"value\": 113.6}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-27T00:00:00\", \"value\": 114.74}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-28T00:00:00\", \"value\": 123.34}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-02-29T00:00:00\", \"value\": 110.45}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-01T00:00:00\", \"value\": 88.94}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-02T00:00:00\", \"value\": 99.32}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-03T00:00:00\", \"value\": 103.16}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-04T00:00:00\", \"value\": 107.46}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-05T00:00:00\", \"value\": 104.42}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-06T00:00:00\", \"value\": 116.29}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-07T00:00:00\", \"value\": 93.85}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-08T00:00:00\", \"value\": 78.34}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-09T00:00:00\", \"value\": 95.86}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-10T00:00:00\", \"value\": 94.8}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-11T00:00:00\", \"value\": 91.52}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-12T00:00:00\", \"value\": 80.45}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-13T00:00:00\", \"value\": 79.75}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-14T00:00:00\", \"value\": 49.01}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-15T00:00:00\", \"value\": 42.38}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-16T00:00:00\", \"value\": 43.54}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-17T00:00:00\", \"value\": 28.09}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-18T00:00:00\", \"value\": 26.75}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-19T00:00:00\", \"value\": 27.13}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-20T00:00:00\", \"value\": 26.78}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-21T00:00:00\", \"value\": 18.94}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-22T00:00:00\", \"value\": 21.62}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-23T00:00:00\", \"value\": 24.92}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-24T00:00:00\", \"value\": 22.92}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-25T00:00:00\", \"value\": 23.28}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-26T00:00:00\", \"value\": 23.78}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-27T00:00:00\", \"value\": 21.86}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-28T00:00:00\", \"value\": 15.46}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-29T00:00:00\", \"value\": 17.89}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-30T00:00:00\", \"value\": 21.95}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-03-31T00:00:00\", \"value\": 22.88}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-01T00:00:00\", \"value\": 22.52}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-02T00:00:00\", \"value\": 21.29}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-03T00:00:00\", \"value\": 22.66}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-04T00:00:00\", \"value\": 14.8}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-05T00:00:00\", \"value\": 16.69}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-06T00:00:00\", \"value\": 19.14}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-07T00:00:00\", \"value\": 21.05}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-08T00:00:00\", \"value\": 19.83}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-09T00:00:00\", \"value\": 21.28}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-10T00:00:00\", \"value\": 19.61}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-11T00:00:00\", \"value\": 14.89}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-12T00:00:00\", \"value\": 15.92}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-13T00:00:00\", \"value\": 19.97}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-14T00:00:00\", \"value\": 19.16}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-15T00:00:00\", \"value\": 23.26}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-16T00:00:00\", \"value\": 21.01}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-17T00:00:00\", \"value\": 24.66}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-18T00:00:00\", \"value\": 14.62}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-19T00:00:00\", \"value\": 17.9}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-20T00:00:00\", \"value\": 19.63}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-21T00:00:00\", \"value\": 19.62}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-22T00:00:00\", \"value\": 20.46}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-23T00:00:00\", \"value\": 20.31}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-24T00:00:00\", \"value\": 21.32}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-25T00:00:00\", \"value\": 15.44}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-26T00:00:00\", \"value\": 17.05}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-27T00:00:00\", \"value\": 19.17}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-28T00:00:00\", \"value\": 21.23}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-29T00:00:00\", \"value\": 21.39}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-04-30T00:00:00\", \"value\": 21.31}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-01T00:00:00\", \"value\": 22.4}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-02T00:00:00\", \"value\": 16.75}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-03T00:00:00\", \"value\": 21.17}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-04T00:00:00\", \"value\": 22.91}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-05T00:00:00\", \"value\": 22.92}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-06T00:00:00\", \"value\": 23.03}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-07T00:00:00\", \"value\": 23.45}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-08T00:00:00\", \"value\": 24.06}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-09T00:00:00\", \"value\": 22.7}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-10T00:00:00\", \"value\": 18.61}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-11T00:00:00\", \"value\": null}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-12T00:00:00\", \"value\": null}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-13T00:00:00\", \"value\": 22.42}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-14T00:00:00\", \"value\": 22.81}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-15T00:00:00\", \"value\": 24.4}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-16T00:00:00\", \"value\": 19.21}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-17T00:00:00\", \"value\": 20.4}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-18T00:00:00\", \"value\": 24.1}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-19T00:00:00\", \"value\": 19.87}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-20T00:00:00\", \"value\": 23.3}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-21T00:00:00\", \"value\": 20.82}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-22T00:00:00\", \"value\": 24.93}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-23T00:00:00\", \"value\": 20.0}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-24T00:00:00\", \"value\": 22.6}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-25T00:00:00\", \"value\": 25.55}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-26T00:00:00\", \"value\": 27.53}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-27T00:00:00\", \"value\": 27.44}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-28T00:00:00\", \"value\": 26.77}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-29T00:00:00\", \"value\": 27.35}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-30T00:00:00\", \"value\": 20.15}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-05-31T00:00:00\", \"value\": 22.0}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-01T00:00:00\", \"value\": 27.64}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-02T00:00:00\", \"value\": 26.8}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-03T00:00:00\", \"value\": 30.03}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-04T00:00:00\", \"value\": 27.13}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-05T00:00:00\", \"value\": 28.01}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-06T00:00:00\", \"value\": 22.91}, {\"geo_type\": \"city\", \"region\": \"San Francisco - Bay Area\", \"transportation_type\": \"transit\", \"alternative_name\": null, \"sub-region\": \"California\", \"country\": \"United States\", \"ds\": \"2020-06-07T00:00:00\", \"value\": 25.2}], \"data-ba117893aec2e1fef8e03e1cf0baa4df\": [{\"ds\": \"2020-06-30T00:00:00\", \"lcl\": 26.71641731262207, \"med\": 34.378108978271484, \"ucl\": 41.343284606933594}, {\"ds\": \"2020-07-31T00:00:00\", \"lcl\": 36.4676628112793, \"med\": 50.398006439208984, \"ucl\": 61.54228973388672}, {\"ds\": \"2020-08-31T00:00:00\", \"lcl\": 53.184078216552734, \"med\": 63.631839752197266, \"ucl\": 73.38308715820312}, {\"ds\": \"2020-09-30T00:00:00\", \"lcl\": 69.90049743652344, \"med\": 80.34825897216797, \"ucl\": 91.49253845214844}]}}, {\"mode\": \"vega-lite\"});\n",
"</script>"
],
"text/plain": [
"alt.LayerChart(...)"
]
},
"execution_count": 8,
"metadata": {},
"output_type": "execute_result"
},
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 8;\n",
" var nbb_unformatted_code = \"hist = (\\n df.query(\\\"region == 'San Francisco - Bay Area'\\\")\\n .query(\\\"transportation_type == 'transit'\\\")\\n .pipe(\\n pd.melt,\\n id_vars=[\\n \\\"geo_type\\\",\\n \\\"region\\\",\\n \\\"transportation_type\\\",\\n \\\"alternative_name\\\",\\n \\\"sub-region\\\",\\n \\\"country\\\",\\n ],\\n var_name=\\\"ds\\\",\\n )\\n .assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\\n .pipe(alt.Chart, title=\\\"SF Transit\\\")\\n .mark_line()\\n .encode(x=\\\"ds\\\", y=\\\"value\\\")\\n)\\n(\\n hist\\n + sf_predictions.pipe(alt.Chart).mark_point().encode(x=\\\"ds\\\", y=\\\"med\\\")\\n + sf_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\\\"ds\\\", y=\\\"lcl\\\", y2=\\\"ucl\\\")\\n)\";\n",
" var nbb_formatted_code = \"hist = (\\n df.query(\\\"region == 'San Francisco - Bay Area'\\\")\\n .query(\\\"transportation_type == 'transit'\\\")\\n .pipe(\\n pd.melt,\\n id_vars=[\\n \\\"geo_type\\\",\\n \\\"region\\\",\\n \\\"transportation_type\\\",\\n \\\"alternative_name\\\",\\n \\\"sub-region\\\",\\n \\\"country\\\",\\n ],\\n var_name=\\\"ds\\\",\\n )\\n .assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\\n .pipe(alt.Chart, title=\\\"SF Transit\\\")\\n .mark_line()\\n .encode(x=\\\"ds\\\", y=\\\"value\\\")\\n)\\n(\\n hist\\n + sf_predictions.pipe(alt.Chart).mark_point().encode(x=\\\"ds\\\", y=\\\"med\\\")\\n + sf_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\\\"ds\\\", y=\\\"lcl\\\", y2=\\\"ucl\\\")\\n)\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"hist = (\n",
" df.query(\"region == 'San Francisco - Bay Area'\")\n",
" .query(\"transportation_type == 'transit'\")\n",
" .pipe(\n",
" pd.melt,\n",
" id_vars=[\n",
" \"geo_type\",\n",
" \"region\",\n",
" \"transportation_type\",\n",
" \"alternative_name\",\n",
" \"sub-region\",\n",
" \"country\",\n",
" ],\n",
" var_name=\"ds\",\n",
" )\n",
" .assign(ds=lambda x: pd.to_datetime(x[\"ds\"]))\n",
" .pipe(alt.Chart, title=\"SF Transit\")\n",
" .mark_line()\n",
" .encode(x=\"ds\", y=\"value\")\n",
")\n",
"(\n",
" hist\n",
" + sf_predictions.pipe(alt.Chart).mark_point().encode(x=\"ds\", y=\"med\")\n",
" + sf_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\"ds\", y=\"lcl\", y2=\"ucl\")\n",
")"
]
},
{
"cell_type": "code",
"execution_count": 9,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 9;\n",
" var nbb_unformatted_code = \"nyc_questions = {\\n date(2020, 6, 30): metaculus.get_question(4567),\\n date(2020, 7, 31): metaculus.get_question(4568),\\n date(2020, 8, 31): metaculus.get_question(4569),\\n date(2020, 9, 30): metaculus.get_question(4570),\\n}\";\n",
" var nbb_formatted_code = \"nyc_questions = {\\n date(2020, 6, 30): metaculus.get_question(4567),\\n date(2020, 7, 31): metaculus.get_question(4568),\\n date(2020, 8, 31): metaculus.get_question(4569),\\n date(2020, 9, 30): metaculus.get_question(4570),\\n}\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"nyc_questions = {\n",
" date(2020, 6, 30): metaculus.get_question(4567),\n",
" date(2020, 7, 31): metaculus.get_question(4568),\n",
" date(2020, 8, 31): metaculus.get_question(4569),\n",
" date(2020, 9, 30): metaculus.get_question(4570),\n",
"}"
]
},
{
"cell_type": "code",
"execution_count": 10,
"metadata": {},
"outputs": [
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 10;\n",
" var nbb_unformatted_code = \"nyc_predictions = pd.DataFrame(\\n [\\n (\\n ds,\\n q.community_dist().percentiles([0.1])[0].max,\\n q.community_dist().percentiles([0.5])[0].max,\\n q.community_dist().percentiles([0.9])[0].max,\\n )\\n for ds, q in nyc_questions.items()\\n ],\\n columns=[\\\"ds\\\", \\\"lcl\\\", \\\"med\\\", \\\"ucl\\\"],\\n).assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\";\n",
" var nbb_formatted_code = \"nyc_predictions = pd.DataFrame(\\n [\\n (\\n ds,\\n q.community_dist().percentiles([0.1])[0].max,\\n q.community_dist().percentiles([0.5])[0].max,\\n q.community_dist().percentiles([0.9])[0].max,\\n )\\n for ds, q in nyc_questions.items()\\n ],\\n columns=[\\\"ds\\\", \\\"lcl\\\", \\\"med\\\", \\\"ucl\\\"],\\n).assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"nyc_predictions = pd.DataFrame(\n",
" [\n",
" (\n",
" ds,\n",
" q.community_dist().percentiles([0.1])[0].max,\n",
" q.community_dist().percentiles([0.5])[0].max,\n",
" q.community_dist().percentiles([0.9])[0].max,\n",
" )\n",
" for ds, q in nyc_questions.items()\n",
" ],\n",
" columns=[\"ds\", \"lcl\", \"med\", \"ucl\"],\n",
").assign(ds=lambda x: pd.to_datetime(x[\"ds\"]))"
]
},
{
"cell_type": "code",
"execution_count": 11,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"\n",
"<div id=\"altair-viz-7f4567eefbec47dc973c1f3dfccbcc31\"></div>\n",
"<script type=\"text/javascript\">\n",
" (function(spec, embedOpt){\n",
" let outputDiv = document.currentScript.previousElementSibling;\n",
" if (outputDiv.id !== \"altair-viz-7f4567eefbec47dc973c1f3dfccbcc31\") {\n",
" outputDiv = document.getElementById(\"altair-viz-7f4567eefbec47dc973c1f3dfccbcc31\");\n",
" }\n",
" const paths = {\n",
" \"vega\": \"https://cdn.jsdelivr.net/npm//vega@5?noext\",\n",
" \"vega-lib\": \"https://cdn.jsdelivr.net/npm//vega-lib?noext\",\n",
" \"vega-lite\": \"https://cdn.jsdelivr.net/npm//vega-lite@4.8.1?noext\",\n",
" \"vega-embed\": \"https://cdn.jsdelivr.net/npm//vega-embed@6?noext\",\n",
" };\n",
"\n",
" function loadScript(lib) {\n",
" return new Promise(function(resolve, reject) {\n",
" var s = document.createElement('script');\n",
" s.src = paths[lib];\n",
" s.async = true;\n",
" s.onload = () => resolve(paths[lib]);\n",
" s.onerror = () => reject(`Error loading script: ${paths[lib]}`);\n",
" document.getElementsByTagName(\"head\")[0].appendChild(s);\n",
" });\n",
" }\n",
"\n",
" function showError(err) {\n",
" outputDiv.innerHTML = `<div class=\"error\" style=\"color:red;\">${err}</div>`;\n",
" throw err;\n",
" }\n",
"\n",
" function displayChart(vegaEmbed) {\n",
" vegaEmbed(outputDiv, spec, embedOpt)\n",
" .catch(err => showError(`Javascript Error: ${err.message}<br>This usually means there's a typo in your chart specification. See the javascript console for the full traceback.`));\n",
" }\n",
"\n",
" if(typeof define === \"function\" && define.amd) {\n",
" requirejs.config({paths});\n",
" require([\"vega-embed\"], displayChart, err => showError(`Error loading script: ${err.message}`));\n",
" } else if (typeof vegaEmbed === \"function\") {\n",
" displayChart(vegaEmbed);\n",
" } else {\n",
" loadScript(\"vega\")\n",
" .then(() => loadScript(\"vega-lite\"))\n",
" .then(() => loadScript(\"vega-embed\"))\n",
" .catch(showError)\n",
" .then(() => displayChart(vegaEmbed));\n",
" }\n",
" })({\"config\": {\"view\": {\"continuousWidth\": 400, \"continuousHeight\": 300}}, \"layer\": [{\"data\": {\"name\": \"data-92521071a53c72be88475bbf035d34c3\"}, \"mark\": \"line\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"value\"}}, \"title\": \"NYC Transit\"}, {\"data\": {\"name\": \"data-b71385abce236c4cca7e182fd4a39bf3\"}, \"mark\": \"point\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"med\"}}}, {\"data\": {\"name\": \"data-b71385abce236c4cca7e182fd4a39bf3\"}, \"mark\": \"errorbar\", \"encoding\": {\"x\": {\"type\": \"temporal\", \"field\": \"ds\"}, \"y\": {\"type\": \"quantitative\", \"field\": \"lcl\"}, \"y2\": {\"field\": \"ucl\"}}}], \"$schema\": \"https://vega.github.io/schema/vega-lite/v4.8.1.json\", \"datasets\": {\"data-92521071a53c72be88475bbf035d34c3\": [{\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-13T00:00:00\", \"value\": 100.0}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-14T00:00:00\", \"value\": 92.66}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-15T00:00:00\", \"value\": 95.29}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-16T00:00:00\", \"value\": 96.42}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-17T00:00:00\", \"value\": 107.5}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-18T00:00:00\", \"value\": 101.22}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-19T00:00:00\", \"value\": 93.41}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-20T00:00:00\", \"value\": 87.91}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-21T00:00:00\", \"value\": 94.76}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-22T00:00:00\", \"value\": 98.07}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-23T00:00:00\", \"value\": 101.52}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-24T00:00:00\", \"value\": 114.06}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-25T00:00:00\", \"value\": 105.16}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-26T00:00:00\", \"value\": 85.92}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-27T00:00:00\", \"value\": 91.57}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-28T00:00:00\", \"value\": 91.79}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-29T00:00:00\", \"value\": 93.18}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-30T00:00:00\", \"value\": 98.02}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-01-31T00:00:00\", \"value\": 110.46}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-01T00:00:00\", \"value\": 109.24}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-02T00:00:00\", \"value\": 83.39}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-03T00:00:00\", \"value\": 91.31}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-04T00:00:00\", \"value\": 92.84}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-05T00:00:00\", \"value\": 93.88}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-06T00:00:00\", \"value\": 97.57}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-07T00:00:00\", \"value\": 111.75}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-08T00:00:00\", \"value\": 117.34}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-09T00:00:00\", \"value\": 89.88}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-10T00:00:00\", \"value\": 91.7}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-11T00:00:00\", \"value\": 95.7}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-12T00:00:00\", \"value\": 97.68}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-13T00:00:00\", \"value\": 103.34}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-14T00:00:00\", \"value\": 118.61}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-15T00:00:00\", \"value\": 113.45}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-16T00:00:00\", \"value\": 95.82}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-17T00:00:00\", \"value\": 100.99}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-18T00:00:00\", \"value\": 99.87}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-19T00:00:00\", \"value\": 102.57}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-20T00:00:00\", \"value\": 104.23}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-21T00:00:00\", \"value\": 115.72}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-22T00:00:00\", \"value\": 117.34}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-23T00:00:00\", \"value\": 87.97}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-24T00:00:00\", \"value\": 91.49}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-25T00:00:00\", \"value\": 92.14}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-26T00:00:00\", \"value\": 94.63}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-27T00:00:00\", \"value\": 97.48}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-28T00:00:00\", \"value\": 114.48}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-02-29T00:00:00\", \"value\": 115.21}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-01T00:00:00\", \"value\": 87.01}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-02T00:00:00\", \"value\": 92.87}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-03T00:00:00\", \"value\": 93.89}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-04T00:00:00\", \"value\": 98.65}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-05T00:00:00\", \"value\": 100.54}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-06T00:00:00\", \"value\": 108.43}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-07T00:00:00\", \"value\": 114.48}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-08T00:00:00\", \"value\": 86.13}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-09T00:00:00\", \"value\": 92.2}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-10T00:00:00\", \"value\": 85.1}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-11T00:00:00\", \"value\": 81.65}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-12T00:00:00\", \"value\": 69.1}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-13T00:00:00\", \"value\": 66.28}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-14T00:00:00\", \"value\": 58.17}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-15T00:00:00\", \"value\": 40.65}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-16T00:00:00\", \"value\": 36.57}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-17T00:00:00\", \"value\": 30.15}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-18T00:00:00\", \"value\": 27.35}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-19T00:00:00\", \"value\": 25.2}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-20T00:00:00\", \"value\": 24.13}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-21T00:00:00\", \"value\": 18.74}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-22T00:00:00\", \"value\": 14.97}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-23T00:00:00\", \"value\": 15.46}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-24T00:00:00\", \"value\": 16.52}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-25T00:00:00\", \"value\": 15.32}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-26T00:00:00\", \"value\": 16.05}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-27T00:00:00\", \"value\": 17.14}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-28T00:00:00\", \"value\": 13.4}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-29T00:00:00\", \"value\": 12.84}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-30T00:00:00\", \"value\": 15.43}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-03-31T00:00:00\", \"value\": 14.55}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-01T00:00:00\", \"value\": 14.39}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-02T00:00:00\", \"value\": 13.84}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-03T00:00:00\", \"value\": 13.76}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-04T00:00:00\", \"value\": 12.71}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-05T00:00:00\", \"value\": 12.03}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-06T00:00:00\", \"value\": 14.26}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-07T00:00:00\", \"value\": 13.54}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-08T00:00:00\", \"value\": 13.32}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-09T00:00:00\", \"value\": 12.73}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-10T00:00:00\", \"value\": 13.37}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-11T00:00:00\", \"value\": 12.52}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-12T00:00:00\", \"value\": 11.25}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-13T00:00:00\", \"value\": 12.75}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-14T00:00:00\", \"value\": 14.13}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-15T00:00:00\", \"value\": 13.42}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-16T00:00:00\", \"value\": 13.34}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-17T00:00:00\", \"value\": 13.46}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-18T00:00:00\", \"value\": 12.1}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-19T00:00:00\", \"value\": 12.61}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-20T00:00:00\", \"value\": 14.58}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-21T00:00:00\", \"value\": 13.49}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-22T00:00:00\", \"value\": 14.06}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-23T00:00:00\", \"value\": 14.03}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-24T00:00:00\", \"value\": 13.83}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-25T00:00:00\", \"value\": 14.08}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-26T00:00:00\", \"value\": 12.19}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-27T00:00:00\", \"value\": 14.98}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-28T00:00:00\", \"value\": 16.01}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-29T00:00:00\", \"value\": 15.39}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-04-30T00:00:00\", \"value\": 14.9}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-01T00:00:00\", \"value\": 16.51}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-02T00:00:00\", \"value\": 16.37}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-03T00:00:00\", \"value\": 15.64}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-04T00:00:00\", \"value\": 18.02}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-05T00:00:00\", \"value\": 17.96}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-06T00:00:00\", \"value\": 17.03}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-07T00:00:00\", \"value\": 17.64}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-08T00:00:00\", \"value\": 16.14}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-09T00:00:00\", \"value\": 15.41}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-10T00:00:00\", \"value\": 14.63}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-11T00:00:00\", \"value\": null}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-12T00:00:00\", \"value\": null}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-13T00:00:00\", \"value\": 18.45}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-14T00:00:00\", \"value\": 18.54}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-15T00:00:00\", \"value\": 20.14}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-16T00:00:00\", \"value\": 19.17}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-17T00:00:00\", \"value\": 17.42}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-18T00:00:00\", \"value\": 20.05}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-19T00:00:00\", \"value\": 20.02}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-20T00:00:00\", \"value\": 20.18}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-21T00:00:00\", \"value\": 20.81}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-22T00:00:00\", \"value\": 21.19}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-23T00:00:00\", \"value\": 18.05}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-24T00:00:00\", \"value\": 19.4}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-25T00:00:00\", \"value\": 20.75}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-26T00:00:00\", \"value\": 23.33}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-27T00:00:00\", \"value\": 23.22}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-28T00:00:00\", \"value\": 22.2}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-29T00:00:00\", \"value\": 23.33}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-30T00:00:00\", \"value\": 24.22}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-05-31T00:00:00\", \"value\": 21.25}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-01T00:00:00\", \"value\": 24.33}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-02T00:00:00\", \"value\": 24.42}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-03T00:00:00\", \"value\": 22.37}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-04T00:00:00\", \"value\": 24.83}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-05T00:00:00\", \"value\": 24.1}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-06T00:00:00\", \"value\": 26.42}, {\"geo_type\": \"city\", \"region\": \"New York City\", \"transportation_type\": \"transit\", \"alternative_name\": \"NYC\", \"sub-region\": \"New York\", \"country\": \"United States\", \"ds\": \"2020-06-07T00:00:00\", \"value\": 25.28}], \"data-b71385abce236c4cca7e182fd4a39bf3\": [{\"ds\": \"2020-06-30T00:00:00\", \"lcl\": 23.23383140563965, \"med\": 37.860694885253906, \"ucl\": 67.81094360351562}, {\"ds\": \"2020-07-31T00:00:00\", \"lcl\": 29.502487182617188, \"med\": 47.611942291259766, \"ucl\": 69.90049743652344}, {\"ds\": \"2020-08-31T00:00:00\", \"lcl\": 38.557212829589844, \"med\": 58.75621795654297, \"ucl\": 81.74129486083984}, {\"ds\": \"2020-09-30T00:00:00\", \"lcl\": 50.398006439208984, \"med\": 71.99005126953125, \"ucl\": 94.97512817382812}]}}, {\"mode\": \"vega-lite\"});\n",
"</script>"
],
"text/plain": [
"alt.LayerChart(...)"
]
},
"execution_count": 11,
"metadata": {},
"output_type": "execute_result"
},
{
"data": {
"application/javascript": [
"\n",
" setTimeout(function() {\n",
" var nbb_cell_id = 11;\n",
" var nbb_unformatted_code = \"hist = (\\n df.query(\\\"region == 'New York City'\\\")\\n .query(\\\"transportation_type == 'transit'\\\")\\n .pipe(\\n pd.melt,\\n id_vars=[\\n \\\"geo_type\\\",\\n \\\"region\\\",\\n \\\"transportation_type\\\",\\n \\\"alternative_name\\\",\\n \\\"sub-region\\\",\\n \\\"country\\\",\\n ],\\n var_name=\\\"ds\\\",\\n )\\n .assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\\n .pipe(alt.Chart, title=\\\"NYC Transit\\\")\\n .mark_line()\\n .encode(x=\\\"ds\\\", y=\\\"value\\\")\\n)\\n(\\n hist\\n + nyc_predictions.pipe(alt.Chart).mark_point().encode(x=\\\"ds\\\", y=\\\"med\\\")\\n + nyc_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\\\"ds\\\", y=\\\"lcl\\\", y2=\\\"ucl\\\")\\n)\";\n",
" var nbb_formatted_code = \"hist = (\\n df.query(\\\"region == 'New York City'\\\")\\n .query(\\\"transportation_type == 'transit'\\\")\\n .pipe(\\n pd.melt,\\n id_vars=[\\n \\\"geo_type\\\",\\n \\\"region\\\",\\n \\\"transportation_type\\\",\\n \\\"alternative_name\\\",\\n \\\"sub-region\\\",\\n \\\"country\\\",\\n ],\\n var_name=\\\"ds\\\",\\n )\\n .assign(ds=lambda x: pd.to_datetime(x[\\\"ds\\\"]))\\n .pipe(alt.Chart, title=\\\"NYC Transit\\\")\\n .mark_line()\\n .encode(x=\\\"ds\\\", y=\\\"value\\\")\\n)\\n(\\n hist\\n + nyc_predictions.pipe(alt.Chart).mark_point().encode(x=\\\"ds\\\", y=\\\"med\\\")\\n + nyc_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\\\"ds\\\", y=\\\"lcl\\\", y2=\\\"ucl\\\")\\n)\";\n",
" var nbb_cells = Jupyter.notebook.get_cells();\n",
" for (var i = 0; i < nbb_cells.length; ++i) {\n",
" if (nbb_cells[i].input_prompt_number == nbb_cell_id) {\n",
" if (nbb_cells[i].get_text() == nbb_unformatted_code) {\n",
" nbb_cells[i].set_text(nbb_formatted_code);\n",
" }\n",
" break;\n",
" }\n",
" }\n",
" }, 500);\n",
" "
],
"text/plain": [
"<IPython.core.display.Javascript object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"hist = (\n",
" df.query(\"region == 'New York City'\")\n",
" .query(\"transportation_type == 'transit'\")\n",
" .pipe(\n",
" pd.melt,\n",
" id_vars=[\n",
" \"geo_type\",\n",
" \"region\",\n",
" \"transportation_type\",\n",
" \"alternative_name\",\n",
" \"sub-region\",\n",
" \"country\",\n",
" ],\n",
" var_name=\"ds\",\n",
" )\n",
" .assign(ds=lambda x: pd.to_datetime(x[\"ds\"]))\n",
" .pipe(alt.Chart, title=\"NYC Transit\")\n",
" .mark_line()\n",
" .encode(x=\"ds\", y=\"value\")\n",
")\n",
"(\n",
" hist\n",
" + nyc_predictions.pipe(alt.Chart).mark_point().encode(x=\"ds\", y=\"med\")\n",
" + nyc_predictions.pipe(alt.Chart).mark_errorbar().encode(x=\"ds\", y=\"lcl\", y2=\"ucl\")\n",
")"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.6"
}
},
"nbformat": 4,
"nbformat_minor": 4
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment