This file contains hidden or 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(future) | |
| library(future.apply) | |
| plan( | |
| strategy = multisession, | |
| workers = 3 | |
| ) | |
| future_lapply( | |
| c("1", 12, NA), | |
| \(x){ | |
| # Mimicking some computational time |
This file contains hidden or 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
| cli::cat_rule("[.Rprofile] Sourcing user-wide rprofile") | |
| options( | |
| usethis.description = list( | |
| `Authors@R` = 'person("Colin", "Fay", | |
| email = "contact@colinfay.me", | |
| role = c("aut", "cre"), | |
| comment = c(ORCID = "0000-0001-7343-1846"))', | |
| License = "MIT + file LICENSE" | |
| ), | |
| usethis.full_name = "Colin Fay", |
This file contains hidden or 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(shiny) | |
| library(xfun) | |
| library(cli) | |
| # Define UI | |
| ui <- fluidPage( | |
| titlePanel("what"), | |
| tags$code( | |
| h3("Sys.getenv()"), | |
| verbatimTextOutput("sysgetenv") | |
| ), |
This file contains hidden or 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
| com <- git2r::commits() |> purrr::map_chr("message") |> tolower() | |
| n_feat <- com |> | |
| grepl("^feat", .) |> | |
| sum() | |
| n_fix <- com |> | |
| grepl("^fix", .) |> | |
| sum() |
This file contains hidden or 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
| alert("hey there") |
This file contains hidden or 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
| r <- httr::GET("https://resultscui.active.com/api/results/events/SchneiderElectricMarathondeParis2022/participants?groupId=943954&routeId=170393&offset=34357&limit=100") |> | |
| httr::content() |> | |
| rawToChar() |> | |
| jsonlite::fromJSON() | |
| base <- 0 | |
| r <- list() | |
| continue <- TRUE | |
| offset <- 0 | |
| r <- httr::GET( |
This file contains hidden or 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
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8"/> | |
| <style>body{background-color:white;}</style> | |
| </head> | |
| <html> | |
| <head> | |
| <title>Title</title> | |
| <link rel="stylesheet" href="https://unpkg.com/leaflet@1.7.1/dist/leaflet.css" |
This file contains hidden or 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) | |
| raw_data <- read_csv("https://www.data.gouv.fr/fr/datasets/r/eb672d49-7cc7-4114-a5a1-fa6fd147406b") | |
| df <- raw_data %>% | |
| filter( | |
| date == as.character( | |
| Sys.Date() - 1 | |
| ) | |
| ) |
This file contains hidden or 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(purrr) | |
| list.files( | |
| pattern = ".Store$", | |
| recursive = TRUE, | |
| full.names = TRUE, | |
| all.files = TRUE | |
| ) %>% | |
| map(unlink, TRUE, TRUE) |
NewerOlder