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
#' Convert ggplot object to dml object to create editable powerpoint slides | |
#' | |
#' @param plot ggplot object or list of ggplot objects | |
#' | |
#' @return a dml object from the ggplot | |
#' @export | |
create_dml <- function(plot){ | |
rvg::dml(ggobj = plot) | |
} |
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
# libraries | |
library(tidyverse) | |
library(DT) | |
set.seed(1234) | |
# generate data | |
dat <- tibble( | |
A = runif(5, 0, 1), | |
B = runif(5, 0, 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(tidyverse) | |
# values to mimic 1 to 7 rating scale with 99 as missing | |
values <- c(1:7, 99) | |
# for reproducibility | |
set.seed(0215) | |
# example data frame with two variables | |
dat <- tibble("A_1" = sample(values, 10, replace = T), |
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) | |
library(rlang) | |
library(glue) | |
# string to append to variable name | |
suffix <- "A" | |
# example data frame | |
dat <- tibble(x = 1:5) %>% | |
# create new variable with walrus operator |
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(sortable) | |
rladies_messages <- c( | |
"R-Ladies creates an inclusive and welcoming environment.", | |
"R-Ladies hosts workshops that help me advance my R programming skills.", | |
"R-Ladies provides a safe place for me to ask technical R questions.", | |
"R-Ladies provides a safe place for me to discuss work-related (but not R) topics.", | |
"R-Ladies facilitates networking opportunities.", |
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
--- | |
title: "hbcus" | |
author: "Shannon Pileggi adapting from Ijeamaka Anyene" | |
date: "2/4/2021" | |
output: html_document | |
--- | |
Conversation on twitter: | |
https://twitter.com/ijeamaka_a/status/1356809290468626434 |