\newpage
This report is just an toy example to see if I can create a package that has (1) an embedded png image, (2) a embedded data set to use internal, (3) can generate an Rdata object generated outside the report, but accessed by it to generate figures and tables.
suppressPackageStartupMessages(library(knitr)) suppressPackageStartupMessages(library(tidyverse)) knitr::opts_chunk$set(warning=FALSE, echo=TRUE, message=FALSE, results='asis', fig.width=6, fig.height=6 )
load(params$Rdatafile)
\newpage
f = system.file("rmarkdown", package="exrender") pic = file.path( f, "skeleton/daisy.png") knitr::include_graphics(pic)
knitr::kable(summary(cars))
A random plot of some
plot(pressure)
\newpage
We made this image in the make_some_data() function and passed it to the report as a paramater that needed to be loaded.
my_plot
\newpage
A table of the first few rows of the embedded data set 'ng_anno'
knitr::kable(ng_anno[1:4,])
x = "my name is moose"
Some in line R code: r x
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.