knitr::opts_chunk$set( collapse = TRUE, warning = FALSE, message = FALSE, comment = "#>", autodep = TRUE ) library(data.table) library(plyr) library(dplyr)
#library(mysimplecompendium) knitr::read_chunk("external.R")
<<set-up-the-data>> df = data %>% filter(skin_color == "fair") %>% select(name, height, mass, homeworld)
library(tidyverse) df %>% ggplot(aes(x = height, y = mass)) + geom_point()
We can see in Figure \@ref(fig:starwars-plot)
df %>% select(name, height, mass, homeworld) %>% knitr::kable(caption = "A knitr kable table of starwars data")
We can see in Table \@ref(tab:starwars-tbl)
knitr::include_graphics("figures/my-image-file.png", dpi = 200)
We can see in Figure \@ref(fig:my-fig) @barba2018terminologies says useful things
about stuff [@barba2018terminologies]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.