The MacroSheds R package provides functions for accessing, manipulating, and analyzing the MacroSheds dataset, a growing collection of stream and watershed data from across North America and beyond.
While built for and around the MacroSheds dataset and project, many functions are also of general value, and can be applied to non-MacroSheds data. Functions are provided to help coax non-MacroSheds data into a suitable format for use with the MacroSheds dataset and package.
To learn more about the MacroSheds project, and to explore the data itself via interactive maps and visualizations, go to the MacroSheds Web Portal.
Table of Contents
Watershed ecosystem science has identified plenty of idiosyncrasy within watersheds, but hasn't produced many general theories about watersheds at large. A major reason has been the challenge of data access and integration across all the organizations that house watershed data. (LTER, CZO/CZ Net, NEON, DOE, USFS, etc.).
MacroSheds unites stream and watershed data from all these sources on one platform, making it easy for anyone to explore the hydrology, water quality, and biogeochemistry of rivers across North America and beyond.
MacroSheds is funded by the U.S. National Science Foundation (Awd. 1926420). MacroSheds aquatic data are collected and provided by U.S. federally funded projects, with limited exception, see notes tab on the MacroSheds Web Portal
To use the MacroSheds R package a user must have at least R version 3.6.1 installed. We recommend the latest R version.
install.packages("devtools")
devtools::install_github("https://github.com/MacroSHEDS/macrosheds.git")
If you'll be using our watershed delineator ms_delineate_watershed
, you'll also need to run
whitebox::wbt_init()
whitebox::install_whitebox()
which initializes the WhiteboxTools geospatial backend and installs its Rust binaries that aren't included on CRAN. More info here.
_For more information about how to use the MacroSheds R package, please refer to the Vignettes. To see the compiled vignettes through your browser, click on the .html or .md files, for example this flux data retrieval and calculation vignette. The .Rmd version of these files can also be compiled using an R interpeter.
For more information about the MacroSheds Project, visit the data portal
Distributed under the MIT License. See LICENSE
for more information.
Project Link: https://github.com/MacroSHEDS/macrosheds/
- Spencer Rhea, [email protected]
- Mike Vlah, [email protected]
- Wes Slaughter, [email protected]