This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Funcao para 1 dia ------------------------- | |
buscar_dados_votacao <- function(data) { | |
# url da API | |
base <- | |
"https://legis.senado.leg.br/dadosabertos/plenario/lista/votacao/" | |
json <- jsonlite::fromJSON(paste0(base, data)) | |
dados <- json |> | |
purrr::pluck("ListaVotacoes") |> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# AUTENTICAR NA TWITCH VIA R -------------------------------------------- | |
# O que está na documentação: | |
# GET https://id.twitch.tv/oauth2/authorize | |
# ?client_id=<your client ID> | |
# &redirect_uri=<your registered redirect URI> | |
# &response_type=<type> | |
# &scope=<space-separated list of scopes> | |
# Adaptando isso para o que precisamos... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#' Author: Bea | |
#' Subject: Tidytuesday de 20 de abril de 2021 | |
library(magrittr, include.only = "%>%") | |
library(ggplot2) | |
# Import ---------------------------------------------------------------------- | |
netflix <- | |
readr::read_csv( | |
'https://raw.githubusercontent.com/rfordatascience/tidytuesday/master/data/2021/2021-04-20/netflix_titles.csv' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#' Copy templates from packages | |
#' | |
#' @param path Character: a path where the files will be copied | |
#' @param pacote name of the package that contains the template | |
#' @param template name of the template: thesis, resume, poster-relaxed, | |
#' poster-jacobs, card ... | |
#' @return | |
#' @export | |
#' | |
#' @examples get_templates_packages("template/", "pagedreport", "windmill") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Código para realizar o sorteio! | |
# Carregar o pipe | |
library(magrittr, include.only = "%>%") | |
# Endereço da planilha gerada pelo Google Forms | |
url <- "https://docs.google.com/spreadsheets/d/1B4VPVsBsJYHVGlXJpKGs-p6fZj7pu-Vlnofpibg1RLc/edit?usp=sharing" | |
# Lê as respostas. | |
# Apenas quem tem acesso a este arquivo vai conseguir fazer essa etapa. | |
# É necessário autenticar! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#' Author: Beatriz Milz | |
#' Subject: Gráfico do volume armazenado no Sistema Cantareira. Dados da sabesp, | |
#' disponíveis no pacote mananciais. | |
library(readr) | |
library(ggplot2) | |
library(magrittr) | |
# Import ----------------------------------------------------------------------- |
NewerOlder