A newer version of the software may be available. See https://code.usgs.gov/wma/vizlab/modeling-drought/-/releases to view all releases.
This repo uses Python and Javascript to build a data visualization website about the methodology behind USGS streamflow drought modeling.
The data visualization website can be viewed at https://water.usgs.gov/vizlab/modeling-drought.
- In the project directory, use a conda environment manager (we recommend Miniforge) to install the environment:
conda env create -f environment.yaml
. - To recreate the data visualizations, use
snakemake --cores 1
. This will rebuild the interactive.svg
images within the webpage. - You can modify the plot scripts by editing the
.py
files inTask1/src
andTask2/src
.
There are other locations in this directory that you may also want to visit to adjust or edit the figures.
- The
Task_Data
directory holds the datafiles used to generate the visualizations - The
Task_config
directory holds aparameters.yaml
file that you can use to adjust the colors and look of the visualizations. It also houses a.py
file with the functions used and the default parameters used formatplotlib
. src/assets/svgs
will house the.svg
files used for the website.
Clone the repo. In the directory, run npm install
to install the required modules. Once the dependencies have been installed, run npm run dev
to run locally from your browser.
To build the website locally you'll need node.js
v22.14.0
and npm
v10.9.2
or higher installed. To manage multiple versions of npm
, you may try using nvm
.
Kwang, Jeffrey, Corson-Dosch, Hayley, Diaz, Jeremy, Archer, Althea, Carr, Mandie, and Nell, Cee. 2025. Modeling Streamflow Drought. U.S. Geological Survey software release. Reston, VA. https://doi.org/10.5066/P14RLGAU
John Hammond consulted on the development of this website as a subject matter expert.
- We welcome contributions from the community. See the guidelines for contributing to this repository on GitHub.
- Disclaimer
- License