Debian Codegraph @

tests/testthat/resources/r-notebook.Rmd

raw
1 ---
2 title: "R Notebook"
3 output: html_notebook
4 ---
5
6 This is an R Markdown Notebook.
7
8 ```{r chunk-one}
9 summary(cars)
10 ```
11
12 This is a plot.
13
14 ```{r chunk-two}
15 plot(cars)
16 ```
17
18 This plot is static.
19
20 ![plot](tinyplot.png)
21
22 This is an HTML widget.
23
24 ```{r chunk-three}
25 if (requireNamespace("dygraphs", quietly = TRUE)) {
26 dygraphs::dygraph(nhtemp, main = "New Haven Temperatures") %>%
27 dygraphs::dyRangeSelector(dateWindow = c("1920-01-01", "1960-01-01"))
28 }
29 ```
30
31 ```{r chunk-four}
32 # The R code in here is ignored; we're
33 # just going to inject some arbitrary HTML.
34 ```
35
36 For more details on using R Markdown see <http://rmarkdown.rstudio.com>.