Skip to content

Instantly share code, notes, and snippets.

View jvfe's full-sized avatar
🐢
slowly but surely!

João Cavalcante jvfe

🐢
slowly but surely!
View GitHub Profile
@jvfe
jvfe / get_covid_data_jhu.py
Last active November 14, 2021 00:05 — forked from fernandobarbalho/get_covid_data_jhu.r
Function to create COVID-19 dataset from JHU github
import pandas as pd
import datetime
def get_covid_data_jhu(dt_ini, dt_fim, us_columns = True, country = None):
date_range = pd.date_range(start = dt_ini, end = dt_fim).to_list()
string_range = [str(d.date().strftime("%m-%d-%Y")) for d in date_range]
full_data_list = []
for dat in string_range:
@jvfe
jvfe / spec2.json
Created May 13, 2020 23:31
Vega spec
{
"config": {"view": {"continuousWidth": 400, "continuousHeight": 300}},
"vconcat": [
{
"hconcat": [
{
"mark": "point",
"encoding": {
"color": {
"condition": {"value": "purple", "selection": "selector079"},
@jvfe
jvfe / spec.json
Last active May 13, 2020 22:50
Vega-Lite spec from Wed May 13 2020
{
"config": {"view": {"continuousWidth": 400, "continuousHeight": 300}},
"vconcat": [
{
"hconcat": [
{
"mark": {"type": "line", "point": true},
"encoding": {
"color": {
"condition": {"value": "purple", "selection": "selector055"},