hydroapps is a package that runs hydrological shiny apps

By Josh Erickson in R Hydrology

August 19, 2021


Lifecycle: experimental

The goal of {hydroapps} is to to create apps for resource management in the context of hydrology monitoring and reporting. This package relies heavily on USGS API and wouldn’t be possible with out it (much thanks). However, this package is highly experimental and is used mostly by myself but I think it’s worth sharing! Please enjoy and contributions are welcome!


As of 08/07/2021 the app is functional. Things to work on:

  • water year and year confusion or ability to make it usable. Right now it uses a weird combo of both…. Not the best 🤷

  • cleaning up code structure and repeating code (especially in ‘usgs_stats’).

  • reduce package dependencies.

  • Any ideas? Please let me know!


This is only in development right now.

And the development version from GitHub with:

# install.packages("devtools")


This package uses the golem framework and thus uses modules to bring everything together. If you want to help contribute please be aware of this framework, i.e. see here for more details. Other than that, contributions are welcomed!

Basic Example

As of right now there are two app options: ‘streamstats’ or ‘usgs_stats’. Just enter the character string into the run_app() and run the app. ‘streamstats’ is a play on the USGS StreamStats Application and also has some commonly used metrics for estimated culvert sizes. ‘usgs_stats’ lets the user select either historic or current stations and get a quick idea of the current daily value as well as a station hydrograph, baseflow index (BFI), flood frequency and time series of maximum flows. In addition, ‘usgs_stats’ includes filters to change the year and months; however, it is important to not that the maximum flows will only use the daily mean maximum if the month is filtered, i.e. maximum flow uses dataRetrieval::readNWISpeak() when months are 1:12 and wildlandhydRo::wymUSGS() otherwise.


Video for streamstats


Posted on:
August 19, 2021
2 minute read, 308 words
R Hydrology
dataRetrieval StreamStats R
See Also:
Graphing Using whitewater