Skip to content

Instantly share code, notes, and snippets.

@dnprock
Created May 25, 2020 21:44
Show Gist options
  • Save dnprock/ebc9ec7629c2957d5d6d61c317d6688e to your computer and use it in GitHub Desktop.
Save dnprock/ebc9ec7629c2957d5d6d61c317d6688e to your computer and use it in GitHub Desktop.
Covid Trend in the United States
{
"name": "Covid Trend in the United States",
"description": "Data from covidtracking.com.",
"columns": 3,
"rows": 3,
"header": {
"align": "center",
"text": "Covid Trend in the United States",
"backgroundColor": "#82ca9d"
},
"data": [
{
"name": "states-current",
"url": "https://covidtracking.com/api/v1/states/current.json"
},
{
"name": "us-daily",
"url": "https://covidtracking.com/api/v1/us/daily.json"
}
],
"charts": [
{
"type": "horizontal-bar",
"data": "states-current",
"title": "Cases by States",
"position": {
"columns": 1,
"rows": 3,
"x": 0,
"y": 0
},
"axes": {
"x": {
"label": "state",
"dataColumn": "state"
},
"y": {
"label": "count",
"dataColumns": [
{
"name": "positive",
"color": "#8884d8"
},
{
"name": "negative",
"color": "#82ca9d"
}
]
}
}
},
{
"type": "line",
"data": "us-daily",
"title": "Positive vs. Death Increase",
"position": {
"columns": 2,
"rows": 1,
"x": 1,
"y": 0
},
"axes": {
"x": {
"label": "date",
"dataColumn": "date",
"dataType": "time",
"dataFormat": "%Y%m%d",
"displayFormat": "%b %d",
"timePrecision": "day"
},
"y": {
"label": "count",
"dataColumns": [
{
"name": "positiveIncrease",
"color": "#8884d8"
},
{
"name": "deathIncrease",
"color": "#82ca9d"
}
]
}
}
},
{
"type": "line",
"data": "us-daily",
"title": "Positive vs. Hospitalized Increase",
"position": {
"columns": 2,
"rows": 1,
"x": 1,
"y": 0
},
"axes": {
"x": {
"label": "date",
"dataColumn": "date",
"dataType": "time",
"dataFormat": "%Y%m%d",
"displayFormat": "%b %d",
"timePrecision": "day"
},
"y": {
"label": "count",
"dataColumns": [
{
"name": "positiveIncrease",
"color": "#8884d8"
},
{
"name": "hospitalizedIncrease",
"color": "#82ca9d"
}
]
}
}
},
{
"type": "line",
"data": "us-daily",
"title": "Positive vs. Negative Increase",
"position": {
"columns": 2,
"rows": 1,
"x": 1,
"y": 0
},
"axes": {
"x": {
"label": "date",
"dataColumn": "date",
"dataType": "time",
"dataFormat": "%Y%m%d",
"displayFormat": "%b %d",
"timePrecision": "day"
},
"y": {
"label": "count",
"dataColumns": [
{
"name": "positiveIncrease",
"color": "#8884d8"
},
{
"name": "negativeIncrease",
"color": "#82ca9d"
}
]
}
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment