Data from tj mahr 🍕 🍍 @tjmahr
library(tidyverse)
library(emoGG)
cheese <- tribble(
~ age, ~ price,
1, 9.99,
2, 10.99,
Data from tj mahr 🍕 🍍 @tjmahr
library(tidyverse)
library(emoGG)
cheese <- tribble(
~ age, ~ price,
1, 9.99,
2, 10.99,
write.csv(iris, "iris.csv")
read_csv_filtered <- function(file, ..., select_vars = NULL, chunk_size = 10) {
stopifnot(requireNamespace("dplyr", quietly = TRUE),
requireNamespace("readr", quietly = TRUE))
filter_by_id <- function(..., select_vars) {
function(.data, pos) {
if (!is.null(select_vars)) .data <- dplyr::select(.data, !!!select_vars)
--- | |
title: "Presentation Ninja" | |
subtitle: "⚔<br/>with xaringan" | |
author: "Yihui Xie" | |
institute: "RStudio, Inc." | |
date: "2016/12/12 (updated: `r Sys.Date()`)" | |
output: | |
xaringan::moon_reader: | |
lib_dir: libs | |
includes: |
#! /usr/bin/env Rscript | |
'usage: | |
create.R project <path> | |
create.R package <path> | |
create.R golem <path> | |
create.R gh <repo_spec> <path> | |
options: | |
<path> Path for creating project or package |
library(tidyverse)
sample_csv <- c(
"sequence;lieu;prevu;reel", "1;UdeS;16:42;16:44", "2;;16:50;16:51",
"3;;16:55;16:55", "4;;16:59;16:58", "5;Gt-US;17:01;17:03", "6;;17:03;17:04",
"7;;17:05;17:05", "8;;17:06;17:06", "9;;17:12;17:10", "10;;17:13;17:11",
"11;Gt-McM;17:16;17:14", "12;;17:17;17:17", "13;;17:19;17:19",
"14;Bel-MM;17:22;17:24", "15;;17:25;17:26", "16;;17:27;17:27",
"17;Csherb;17:28;17:28", "18;;17:29;17:29", "19;Kg-Bel;17:32;17:30",
library(shiny) | |
library(purrr) | |
ui <- fluidPage( | |
textInput("inputId", "inputId", value = "number"), | |
helpText("Create a new input ID for the dropdown below"), | |
selectInput("number", "Renamable", choices = letters[1:5], selected = 1), | |
helpText("Notice that old inputs stick around..."), | |
verbatimTextOutput("debug"), | |
tags$script(HTML( |
library(shiny) | |
library(purrr) | |
ui <- fluidPage( | |
tags$head( | |
tags$link(rel = "//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"), | |
tags$script(src = "https://code.jquery.com/ui/1.12.1/jquery-ui.js"), | |
tags$link(href = "style.css", rel = "stylesheet") | |
), | |
fluidRow( |
library(shiny) | |
# Here's a simple text module that with one text input and that shows a local result | |
textModUI <- function(id, label = "Word") { | |
ns <- NS(id) | |
tagList( | |
textInput(ns("word"), label), | |
verbatimTextOutput(ns("result")) | |
) | |
} |
typingStatsUI <- function(id) { | |
ns <- NS(id) | |
tagList( | |
fluidRow( | |
div( | |
class = "col-xs-12 col-sm-9 col-md-6", | |
uiOutput(ns("prompt")) | |
), | |
div( | |
class = "col-xs-12 col-sm-3 col-md-6", |