Skip to content

Instantly share code, notes, and snippets.

View romainfrancois's full-sized avatar
🎉
tada⬢science ⬡⬡ ex(Posit/RStudio, ThinkR, Mango Solutions)

Romain François romainfrancois

🎉
tada⬢science ⬡⬡ ex(Posit/RStudio, ThinkR, Mango Solutions)
View GitHub Profile
suppressMessages(library(tidyverse))
musique <- jsonlite::read_json("https://www.data.gouv.fr/fr/datasets/r/0dba0390-5eba-401f-aae5-933243c0b163", simplifyDataFrame = TRUE)$fields
musique %>%
pull("keywords_fr") %>%
str_split(";") %>%
flatten_chr() %>%
table() %>%
enframe() %>%
library(dplyr)
library(purrr)
df <- tribble(
~x, ~y,
"a", "b",
"c", "b",
"b", "a",
"b", "b",
"a", "a"
@romainfrancois
romainfrancois / dplyr_erum.R
Created June 29, 2020 07:17
code used in my dplyr talk at e-Rum 2020
library(dplyr, warn.conflicts = FALSE)
library(palmerpenguins)
# multiple rows
penguins %>%
group_by(species) %>%
summarise(
prob = c(.25, .75),
length = quantile(bill_length_mm, prob, na.rm = TRUE),
depth = quantile(bill_depth_mm, prob, na.rm = TRUE)
romainfrancois@sherlox /tmp % brew install apache-arrow --HEAD -v
==> Downloading https://github.com/apache/arrow/commit/ae60bad1c2e28bd67cdaeaa05f35096ae193e43a.patch?full_index=1
Already downloaded: /Users/romainfrancois/Library/Caches/Homebrew/downloads/bebaf2a7625dae0afc3e8aca8f0a05cd8f341811c2661341315d537706ac2cfc--ae60bad1c2e28bd67cdaeaa05f35096ae193e43a.patch
==> Verifying bebaf2a7625dae0afc3e8aca8f0a05cd8f341811c2661341315d537706ac2cfc--ae60bad1c2e28bd67cdaeaa05f35096ae193e43a.patch checksum
==> Cloning https://github.com/apache/arrow.git
Updating /Users/romainfrancois/Library/Caches/Homebrew/apache-arrow--git
git config remote.origin.url https://github.com/apache/arrow.git
git config remote.origin.fetch \+refs/heads/master:refs/remotes/origin/master
git config remote.origin.tagOpt --no-tags
git fetch origin