Skip to content

Latest commit

 

History

History
31 lines (19 loc) · 3.74 KB

README.md

File metadata and controls

31 lines (19 loc) · 3.74 KB

Supporting Information

This repository holds all supplementary source code needed to reproduce the calculations and plots of the following manuscript:

Asamoto CK, Rempfert KR, Luu VH, Younkin AD, Kopf SH. Enzyme-Specific Coupling of Oxygen and Nitrogen Isotope Fractionation of the Nap and Nar Nitrate Reductases. Environmental Science & Technology (2021). doi:10.1021/acs.est.0c07816.

The fully compiled analysis files are available as HTML reports. For the easiest way to run the source R Markdown (.Rmd) files that produce these HTML reports yourself along with the data figures in PDF and PNG format and the data tables in XLSX format, please follow the instructions below.

What can I do with this code?

We hope that this code, or any part of it, might prove useful to other members of the scientific community interested in the subject matter. This repository is released under a Creative Commons BY (CC-BY) license, which means all code can be shared and adapted for any purpose as long as appropriate credit is given. See Attribution section for details.

What is R Markdown?

R Markdown is a so-called "literate programming" format that enables easy creation of dynamic documents with the R language. HTML and PDF reports can be generated from R Markdown files using knitr and pandoc, which can be installed automatically with RStudio, and are fully integrated into this cross-platform IDE. All software used for these reports (R, RStudio, etc.) is freely available and completely open-source.

How can I run this code?

The quickest and easiest way is to use RStudio.

  1. Download and install R for your operating system
  2. Download and install RStudio for your operating system
  3. Download a zip file of this repository and unpack it in an easy to find directory on your computer
  4. Navigate to the directory and double-click the project.Rproj file to start RStudio and load this project.
  5. Install the required libraries by running the following command in the Console in RStudio: install.packages(c("tidyverse", "latex2exp", "cowplot", "broom", "phangorn", "openxlsx", "BiocManager")) followed by BiocManager::install("ggtree") or by installing them manually in RStudio's Packages manager.
  6. Open any of the R Markdown (.Rmd) files in the file browser
  7. To generate an HTML report ("knit HTML"), select File --> Knit from the menu. The HTML report will be displayed upon successful completion and is saved as a standalone file in the same directory (these are the files made available online and linked in the SI). All generated data figures are saved as PDF and PNG in the figures sub-directory. All generated data tables are saved as XLSX in the tables sub-directory.

Troubleshooting notes

The R Markdown files in this repository make use of various R modules for data processing, plotting and modelling. All of these should be installed automatically when the first R Markdown file is knitted (if the knitting fails because of a missing package, please install it manually, an error will indicate which package could not be installed).