This is where materials live for the Reproducible Research and Collaboration lunchtime workshop at the ESA meeting in Minneapolis.
This is ESA session 9069.
Date: 2013-08-05, Monday
Time: 11:30 AM-1:15 PM
Where: 101D, Minneapolis Convention Center
Workshop description from the ESA website:
The typical mode of collaborative writing in ecology consists of emailing Microsoft Word documents back and forth with different file names and track changes. The result is often a confusing mishmash of multiple versions of manuscripts, with different versions of figures and analysis - resulting in non-reproducible science. A long standing alternative is LaTeX/Sweave, a framework where snippets of R code are integrated into a Latex document, allowing collaborators to edit both R code and manuscript text into one document that can be rendered to PDF, html, Word, etc. A barrier to using LaTeX for many ecologists is that ecology as a discipline has no tradition of using LaTeX, which has a steep learning curve. Recently this framework of integrated code with manuscript text has been made easier with the release of knitr (http://yihui.name/knitr/), which uses Markdown (MD) instead of LaTeX. MD (http://daringfireball.net/projects/markdown/) is a simple text formatting syntax that can be quickly learned in just a few minutes. In addition, MD is much more human readable than LaTeX, facilitating collaborations. Last, writing documents in MD makes version control easier than ever using tools like git. Our workshop will focus on how knitr/MD can be used to generate reproducible research documents that ecologists can work on collaboratively, and even generate publication quality PDF’s. We will cover the basics of the MD syntax, how knitr code-snippets work, and how to include citations. We will demonstrate how version control systems can be used for collaborative writing. Attendees will leave with the skills to write their own reproducible research documents with integrated formatting of text and R code and figures.
What we'll cover:
- Markdown
- Why use it
- Syntax
- Use cases
- Practice
- knitr
- How to write reproducible documents
- Demonstrate how to make nice PDF's
- Git
- Demonstration of using git to version control your markdown files
What to do/bring before the workshop
- Bring your own laptop
- Install a Markdown reader (some options for free/cheap apps - just some ideas - look around for yourself)
- Mac: Mou (free), Marked ($4),
- windows: MarkdownPad (free)
- Linux: UberWriter
- Install RStudio
- Install the following libraries in your R installation:
- knitr and any dependencies
Optional installation
Instructors
Contributors
The main file for the prsentation is index.Rmd
Compile the file to slides:
- install R packge slidify:
install_github("slidify", "ramnathv", ref="dev")
- install R packge slidifyLibraries:
install_github("slidifyLibraries", "ramnathv", ref="dev")
- Then load the two packages
library(slidify); library(slidifyLibraries)
- Go to the directory on your machine where this is
- run
slidify("index.Rmd")
, and it will output a file index.html that you can open in browser and examine - edit stuff, commit changes, push
notes:
- custom css is in the file
assets/css/esamd.css
- images in
assets/img/