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
library("tidyverse") | |
library("fivethirtyeight") | |
library("ggrepel") | |
library("hrbrthemes") | |
library("ggtext") | |
bechdel_complete <- bechdel %>% | |
drop_na() %>% | |
mutate(profitable = budget_2013 <= domgross_2013) |
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
library(tidyverse) | |
library(ggraph) | |
library(tidygraph) | |
nodes_characters <- starwars %>% | |
mutate(character_id = row_number(), .before = 0) %>% | |
mutate(across(where(is.list), ~lengths(.x), .names = "n_{.col}")) | |
edges_reoccuring_co_stars <- nodes_characters %>% |
We can make this file beautiful and searchable if this error is corrected: Illegal quoting in line 3.
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
tibble::tribble( | |
~country, ~year, ~month, ~name, ~value, | |
"Australia", 2011L, "January", "births", 24550L, | |
"Australia", 2011L, "January", "deaths", 11483L, | |
"Australia", 2011L, "February", "births", 23209L, | |
"Australia", 2011L, "February", "deaths", 10522L | |
) |
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
function(input, output, session){ | |
output$curve_plot <- renderPlot({ | |
print(input$exponent) | |
curve(x^as.integer(input$exponent), from = -5, to = 5) | |
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
devtools::install_github("charliejhadley/rdocsanalysis") | |
library(tidyverse) | |
dplyr_docs <- rdocsanalysis::process_pkg_docs("dplyr", version_number = "1.0.0") |
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
date_quote | date_purchase | flag | |
---|---|---|---|
2020-08-15 | 2020-09-28 | TRUE | |
2020-07-27 | 2020-09-09 | FALSE | |
2020-07-22 | 2020/09/04 | FALSE | |
2020-08-22 | 2020-10-05 | TRUE | |
2020-04-14 | 2020-05-28 | TRUE | |
2020-05-27 | 2020/07/10 | TRUE | |
2020-03-20 | 2020-05-03 | FALSE | |
2020-03-15 | 2020/04/28 | FALSE | |
2020-01-12 | 2020/02/25 | FALSE |
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
library(tigris) | |
library(sf) | |
library(rmapshaper) | |
library(readxl) | |
library(janitor) | |
library(leaflet) | |
library(tidyverse) | |
# ==== Streaming Data ==== | |
# Data obtained from https://kiss951.com/2021/05/20/national-streaming-day-list-of-the-most-popular-streaming-services-in-each-state/ |
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
library(tidyverse) | |
data_waterfall_raw <- read_csv("waterfall.csv") | |
data_waterfall_clean <- data_waterfall_raw %>% | |
mutate(order = row_number()) %>% | |
mutate(event = str_wrap(event, 12)) %>% | |
mutate(event = fct_reorder(event, order)) %>% | |
mutate( | |
end = cumsum(change), |
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
library(tidyverse) | |
library(lubridate) | |
library(bbplot) | |
library(ggtext) | |
# values for five-year mortgages are inaccurately read from the original graphic by BBC | |
# https://twitter.com/charliejhadley/status/1576992785638772736?s=20&t=DTM3oBSGAsSOQ2SIrvUB-A | |
mortgage_rates <- tribble( | |
~date, ~rate, ~deal, |
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
--- | |
title: "Quarto" | |
format: html | |
echo: false | |
message: false | |
warning: false | |
--- | |
```{r load-packages} | |
library(tidyverse) |
NewerOlder