Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dr-harper/example-rmd-templates
📄 A selection of minimal examples used to highlight R Markdown templates, as referred to in the "R Markdown Definitive Guide"
https://github.com/dr-harper/example-rmd-templates
bookdown pandoc r rmarkdown rmarkdown-templates
Last synced: 3 months ago
JSON representation
📄 A selection of minimal examples used to highlight R Markdown templates, as referred to in the "R Markdown Definitive Guide"
- Host: GitHub
- URL: https://github.com/dr-harper/example-rmd-templates
- Owner: dr-harper
- Created: 2018-04-27T16:02:30.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-04-05T12:00:28.000Z (almost 2 years ago)
- Last Synced: 2024-07-15T16:55:53.791Z (6 months ago)
- Topics: bookdown, pandoc, r, rmarkdown, rmarkdown-templates
- Language: HTML
- Homepage: https://bookdown.org/yihui/rmarkdown/document-templates.html
- Size: 340 KB
- Stars: 90
- Watchers: 1
- Forks: 76
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - dr-harper/example-rmd-templates - 📄 A selection of minimal examples used to highlight R Markdown templates, as referred to in the "R Markdown Definitive Guide" (HTML)
README
R Markdown Templates: Minimal Examples
======================================================This repository provides a couple of minimal examples of R Markdown templates. If you are reading this, you have likely found about example in [Chapter 17](https://bookdown.org/yihui/rmarkdown/document-templates.html#) in the R Markdown definitive guide book.
The repository contains several basic examples:
- **My Template**: shows a minimal R Markdown template, defining several styles for HTML outputs.
- **My Template (Extra Files)**: includes a custom logo and a `style.css` file to change the style of tables.
- **My Template (HTML edits)**: uses a custom HTML template to add a customisable footer to the document.
- **My Template (LaTeX edits)**: uses a custom LaTeX template which adds extra fields to the header.
- **My Template (Custom Format)**: this uses a custom R Markdown format to use extra files without a copy having to be made to the directory (see [Chapter 18](https://bookdown.org/yihui/rmarkdown/new-formats.html))These templates are purposely very basic, being designed to demonstrate how custom styles can easily be created. You may wish to fork the repository to customise the designs further.
## Installing the Templates
If you want to trial these templates within R Markdown, you can install the templates directly:
```
# install.packages("devtools")
devtools::install_github("mikey-harper/example-rmd-templates")
```This will install the package `MyTemplates`. Once installed, they will be available within the R Markdown templates as shown below:
![R Markdown templates](https://i.imgur.com/Cnlbhsm.png)
## Adapting the Templates
If you want to use the package as a base for your own template, you may want to fork the repository. It will help to read [Chapter 17](https://bookdown.org/yihui/rmarkdown/document-templates.html#) and [Chapter 18](https://bookdown.org/yihui/rmarkdown/new-formats.html) to find out more about this.