Created
December 9, 2019 23:02
-
-
Save colearendt/d16d39b310ddf7a252053ca047748775 to your computer and use it in GitHub Desktop.
blastula/gt reprex 20191209
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
--- | |
output: blastula::blastula_email | |
--- | |
```{r email_setup, include=FALSE} | |
knitr::opts_chunk$set(echo = FALSE) | |
report_url <- Sys.getenv("RSC_REPORT_URL") | |
``` | |
## Test Email | |
```{r gt_output} | |
gt_data | |
``` | |
This document is available at `r report_url`. |
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: "email-reprex-20191209" | |
author: "Cole Arendt" | |
date: "12/9/2019" | |
output: html_document | |
--- | |
```{r setup, include=FALSE} | |
knitr::opts_chunk$set(echo = TRUE) | |
library(gt) | |
library(blastula) | |
``` | |
```{r generate} | |
gt_data <- iris %>% | |
gt() %>% | |
tab_header( | |
title = md("**TEST TEST**") | |
) %>% | |
tab_spanner( | |
label = "Sepal", | |
columns = vars(Sepal.Length, Sepal.Width) | |
) %>% | |
tab_spanner( | |
label = "Petal", | |
columns = vars(Petal.Length, Petal.Width) | |
) %>% | |
tab_options( | |
heading.background.color = "#9fa9a3", | |
column_labels.background.color = "#c5d5c5", | |
row_group.background.color = "#e3e0cc", | |
table.background.color = "#f0f0f0" | |
) | |
gt_data | |
``` | |
```{r email} | |
blastula::render_connect_email('email-20191209.Rmd') %>% | |
blastula::attach_connect_email( | |
subject = "Test Reprex" | |
) | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment