Complete pass through Rmarkdown

This commit is contained in:
hadley
2016-08-22 15:27:54 -05:00
parent 166a1b96d7
commit 545ca5b13c
5 changed files with 235 additions and 156 deletions

View File

@@ -4,15 +4,11 @@ output: html_document
---
```{r include = FALSE}
# colorFunc <- "heat.colors"
colorFunc <- "terrain.colors"
# colorFunc <- "topo.colors"
# colorFunc <- "cm.colors"
# colorFunc <- "rainbow"
```
Base R comes with many functions for generating colors. The code below demonstrates the `r colorFunc` function.
Base R comes with many functions for generating colors. The code
below demonstrates the `r colorFunc` function.
## `r colorFunc`

View File

@@ -10,10 +10,11 @@ library(marmap)
library(ggplot2)
```
The [marmap](https://cran.r-project.org/web/packages/marmap/index.html) package provides tools and data for visualizing the ocean floor. Here is an example contour plot of marmap's ``r params$data`` dataset.
The [marmap](https://cran.r-project.org/web/packages/marmap/index.html)
package provides tools and data for visualizing the ocean floor. Here
is an example contour plot of marmap's ``r params$data`` dataset.
```{r echo = FALSE}
data(list = params$data)
autoplot(get(params$data))
```

View File

@@ -20,8 +20,6 @@ Headings
### 3rd Level Header
#### 4th Level Header
Lists
------------------------------------------------------------
@@ -35,11 +33,13 @@ Lists
1. Numbered list item 1
2. Item 2
1. Item 2. The numbers are incremented automatically in the output.
3. Item 3
+ Item 3a
+ Item 3b
1. Item 3
1. Item 3a
1. Item 3b
Links
------------------------------------------------------------
@@ -58,33 +58,11 @@ Images
![optional caption text](path/to/img.png)
```
Footnotes
Tables
------------------------------------------------------------
A [linked phrase][id].
Then below:
[id]: text of the note
Block quotes
------------------------------------------------------------
As George Box said:
> All models are wrong
> but some are useful.
Tables ---------------------------------------------------
First Header | Second Header
------------- | -------------
Content Cell | Content Cell
Content Cell | Content Cell
Reference Style Links and Images
Equations -----------------------------------------------
$E = mc^{2}$
$$E = mc^{2}$$