In November 2022, I posted a tutorial on how to use the US Geological Survey’s web service NLDI to delineated watersheds in the continental United States. Since then, they updated the API, and that old code no longer works. Here is an updated Python script. I’m using the library pynhd, which gives convenient access to the NLDI. You could also use the API directly with the requests library.
This NLDI gives access to data from the National Hydrography Dataset Plus version 2. This is an older version of the NHD that is no longer being updated. At this time, the USGS does not have an API to access the latest version of its geodata, the 3DHP. So if you wanted to use those data for watershed delineation, I suppose you would have to download the data and use GIS or write your own routines.
Let me know what you think. Would you be interested in a Python package that you could install with pip? What kind of output is most useful?
Now the Global Watersheds web app can use USGS data and methods (NLDI) to delineate watersheds in the continental United States. This means more accurate watersheds and flow paths in the US.
To access it, make sure to do a full reload of the page: https://mghydro.com/watersheds. In most browsers, you can hit: Ctrl + Shift + R or Ctrl + F5.
To use the USGS option, click on Options, then under Data Source, select “USGS.”
Here, the app is using a free API from the USGS called the Hydro Network Linked Data Index, or NLDI. This option was available a couple of years ago, but at one point, the USGS updated their API and it broke my code. It took me a while to get around to fixing it!
A few notes: Sometimes the USGS API will time out without returning results. I’ve set up the app to automatically retry 3 times, but if you get an error message, please wait a moment and try again. You can also try clicking on a slightly different point, like 0.001° from your original request. Be patient — their server can take a few minutes sometimes.
I’ve also added another feature that should help you to get good results — the NHDv2 Flowlines layer on the map. (The National Hydrography Dataset version 2 is the dataset used by USGS for the NLDI.) In the map layer selector at the upper right, choose this layer at the bottom of the list. (See image below.)
To get good watershed delineation results, click on the flowline for the river whose watershed you are seeking. This will help snap the pour point correctly. This should help reduce the spurious small tributary watersheds that often come up.
More about the National Hydrography Dataset
The NHD is “the nation’s water data backbone,” and gives access to geodata that has been compiled by state and federal agencies over the course of decades. Unfortunately, the version used by the NLDI is not the latest hydrography dataset created by the USGS. The naming of the different versions of the NHD is confusing, but as best as I can tell, the NLDI is based on NHD v2. This version was released in 2012, and was digitized from maps at the 1:100,000-scale. There is a later version called NHDPlus HR, for “high-resolution,” which was never quite completed for the whole nation. As of 2023, this is no longer being developed, and the USGS is now focused on creating a hydrography data product called 3DHP. There is not yet an API to access these datasets, but they are available for download.
One quirky thing about the NHD is that it is only for the continental United States, affectionately referred to as CONUS. So you will see missing data around the border with Mexico and Canada. For example, here is the watershed of the Tijuana River — the watershed boundaries are complete, but most of the rivers in Mexico are missing.
Let me know how this new feature works for you. I always like hearing from folks using the app. If you found the app helpful, consider supporting the site by buying me a coffee! ☕☺️
If you’ve studied hydrology or climate science, you’ve probably come across the Budyko curve, or the Budyko Framework. Soviet climatologist Mikhail Ivanovich Budyko published what is now the well known Budyko curve, a conceptual model describing the relationship between the water and energy balances of a catchment or region. It has been hotly debated for decades and scientists still write hundreds of papers about it every year.
I was curious about the original source for this. Some sources report it as Budyko’s Book Water for Life, published by UNESCO in 1974. However, the original publication predates this by almost 20 years. And I was surprised to find it, of all places, on the website of the CIA!
I cleaned up the PDF by cropping the pages, running character recognition, and compressing the images. You’ll find the famous Budyko curve at the top of page 74 in the book (page X in the PDF).
Citation: Budyko, M. I. (1956). Teplovoĭ Balans Zemnoĭ Poverkhnosti (Heat Balance of the Earth’s Surface). Gidrometeorologischeskoe izdatel’stvo (Hydrometeorological Publishing House), Leningrad, USSR (Translated by N. A. Stepanova, U.S. Weather Bureau, 1958, 259 pages).
If you enjoyed adding this classic to your library, consider buying me a coffee. 🙂
I’ve just published a bunch of updates to the free Global Watersheds web app. Please check them out, and, as always, let me know if you have any questions or comments. I always love hearing from folks who use the app.
New Thematic Map Layers
Did you know you can change the basemap shown on the map, by clicking the layer selector at the top right? I’ve added three new thematic map layers — population density, land cover, and irrigated lands. These layers help illustrate human activities that can have big impacts on watersheds.
I chose to use a datalayer of population called GlobPop, by researchers in Beijing. This seemed to be the best among the alternatives I looked at (GPW4, GRUMP, LandScan, and WorldPop). This was actually quite surprising, as some of these other datasets are well-known and backed by large institutions.
Three new thematic map layers. Population density is shown here.
The thematic map layers were developed by different teams of researchers using satellite imagery and machine learning. While they’re not perfect, they show how these tools can help us better understand our planet. I’m particularly excited to show you the “slider” feature on that lets you compare land cover in 2000 and 2020.
This example shows the area around Bamako, the capital of Mali in West Africa. The Niger River traverses the scene from the southwest to the northeast. Bamako’s footprint grew enormously in the last two decades. You can also see forested and shrubland that have been converted to farmland.
Another new layer displays dams from the Global Dam Watch database. It contains a total of 41,145 dams.
For more information about where these data come from, you can visit the About / Help page, or create a Watershed Data Report.
Watershed Data Report
After you’ve created a new watershed, you’ll see a new blue button on the left-side menu. Click this button to create a Watershed Data Report. The report summarizes a variety of information about the watershed:
I included some text in each section containing a brief introduction on how human and environmental factors affect watersheds.
Political Boundaries
Population
Land Cover
Hydrology
GRACE Total Water Storage
Irrigation
Dams
Some of the information in the report comes from the thematic layers that you can display on the map (for example, population, irrigated area, and land cover). The app calculates sums or averages over the pixels that overlap the watershed. In geographic information science, or GIS, this is referred to as “zonal statistics.” For a discussion of how I do these calculations, see Section 3.4 in my PhD thesis, Calculating Basin Means of [Gridded] Earth Observation Variables.
Snippet of the Watershed Data Report. This one is for the Apalachicola-Chattahoochee-Flint River Basin, which has seen significant population growth, urban expansion, and loss of forests and cropland.
Finally, if you found the app useful for your classroom, business, or research, why not show your appreciation by buying me a cup of coffee?
Let me know if you found something interesting in your watershed report. How do you think this information could be useful for education, advocacy, or management? Are there any other environmental datasets you’d like to see included?
The water quality of the Seine has been making headlines, thanks to the 2024 summer Olympics in Paris. A few days ago, I discussed these issues with Kelly Yu from Radio Hong Kong.
I did my Master’s thesis on bacteria contamination of urban rivers, so it’s something I know a bit about… Paris has invested massively in improvements to the wastewater system, but much more needs to be done before the Seine will be consistently able to meet water quality standards for swimming.
This map shows the watershed, or drainage basin, upstream of Pont Alexandre III in Paris, where the Olympic open-water swimming events will be held:
The watershed covers 44,000 square kilometers, and includes cities, suburbs, farms, and forests. The watershed is an important determinant of the water quality in a river. In this case, every time it rains, pollutants are washed off of land surfaces and into lakes, rivers, and streams. Here is what I wrote about nonpoint source pollution in my MS thesis in 2003:
Runoff from land areas in the watershed is also a significant pathway by which bacteria enter surface waters. Urban runoff typically contains a variety of pollutants, including organic matter, oil and grease, nutrients, pesticides and herbicides, as well as bacteria and viruses. Bacteria in runoff can come from waste from pets and wildlife or may be attached to soil particles. In an urban setting, where storm drains are designed to get water away from roads and buildings as quickly as possible, nonpoint source pollutants are quickly delivered to surface waters, with little time for settling or decay to occur.
Paris also has a major illicit discharge problem, where boats and homes discharge sewage water directly to rivers or streams. I learned about this in an excellent article from the NY Times; this topic has received scant coverage in French-language media.
Wikipedia has thousands of articles about rivers. What are the most important facts about a river? Some can be described with numbers, such as its length, width, or average flow.
I think that every Wikipedia article about a river should include a watershed map. A map can tell you so much, including the landscape features that affect a river’s flow and water quality.
You can make a high-quality map using the free Global Watersheds web app. It is fast and easy. The best part is that you can include a link to a live, interactive map. Below is an example, followed by step-by-step instructions.
I defended my PhD thesis* in January, and decided it would be nice to put it online in HTML format. I have posted it here. The PDF is available via France’s open science portal HAL.
Heberger, Matthew. 2024. Improved observation of the global water cycle with satellite remote sensing and neural network modeling. PhD thesis. Sorbonne University, Paris, France. https://theses.hal.science/tel-04517802v1
My research had to do with using remote sensing data to describe the water cycle at the global scale, and explored methods to improve these data. There have been quite a few studies on this subject in the last several years, but we did a few things differently, namely using a much larger database of observations than previous studies, and using neural network models with some unique features. A few members of my committee said found my writing “pedagogic” and plan to share certain parts with their students. I hope that it is of some use to students or others interested in hydrology and remote sensing.
The PDF is formatted nicely and better for print. But the web version is nicer to read on a wider range of devices. It can also be resized or reformatted for easier reading. (When I’m reading long online documents, I like to use Firefox’s reader view.)
I used Latex and Overleaf to prepare the manuscript. I was hoping that it would be straightforward to convert to HTML. Unfortunately, it was not! I used the software pandoc to convert the document, but it required a lot of manual cleanup. Please let me know if you see any weird formatting or typos!
* In the US, it is customary to talk about a Master’s thesis, and a PhD dissertation. Under the British educational system, it’s the opposite. And in France, to obtain a doctoral degree, one writes une thèse.
You can now delineate watersheds that drain to a polyline or polygon feature. This is useful for finding the total drainage area for a section of coastline or for an inland lake — also known as “endorheic” lakes.
To use this feature, under Options, check the box for Delineate watersheds for a lake or coastline. On the left side of the map, you will see a new drawing toolbar. Select one of the drawing tools, and create a polyline, polygon, rectangle or circle. You can only draw one feature at a time. There are also little buttons to edit your feature or to delete it. Then click on the feature and then click the button Delineate! This feature is only available using MERIT data (not HydroSHEDS), and only in “lower-resolution” mode.
In the example below, I found the area that drains to the Gulf of Bejaia on the Mediterranean coast in Algeria, by drawing a line over the land near the coast:
The resulting drainage area includes two larger rivers or “wadis,” as well as many smaller coastal drainages.
The second new feature allows you to view the MERIT-Basins layers on the map. There are separate layers for “river reaches” and “unit catchments.” These are the data layers that the app uses to construct watersheds when you choose “MERIT” as your data source. To activate these layers, just click on these new layers. They are overlays, which will display on top of your chosen basemap.
Finally, a small but fun new feature: you can now change the color of your rivers and watershed boundaries. You’ll find the color selectors near the bottom of the Options pane on the left. I’m not sure this is very useful, but you can create some interesting effects:
Please let me know what you think of these new features. Did you find any bugs? How could you use them?
I put together this list of journals with some info on their fees during my PhD research, and I’m sharing it here in case others may find it helpful. This information is likely to change fast, so make sure to verify.
During my PhD research, I became a convert to Latex for scientific writing, specifically using the website Overleaf.com. However, one feature that is missing is a good spelling and grammar checker. I like to use Microsoft Word for copyediting, as it has good built-in tools, and there are also plenty of addins available, like grammarly and ProWritingAid.
But first you need to get a clean export from Latex to Word, which is not straightforward.
Here is a method that works using Google Drive. It does not do a good job converting figures, tables, and equations, so I suppress those before continuing. It also helps to turn off hyphenation.
Add the following block to the preamble of the Latex document.