Shreve stream magnitude

This tool can be used to assign Shreve's stream magnitude to each link in a stream network. Stream magnitude is equal to the number of headwater links upstream of each link. Headwater stream links are assigned a magnitude of one. Strahler's stream order is a common alternative stream numbering scheme.

The user must specify the names of a streams raster image and D8 pointer image. Stream cells are designated in the streams image as all positive, nonzero values. Thus all non-stream or background grid cells are commonly assigned either zeros or NoData values. The pointer image is used to traverse the stream network and should only be created using the D8 algorithm. Background cells will be assigned the NoData value in the output image. The output raster is of an integer data type and continuous data scale.

See Also:


The following is an example of a Python script that uses this tool:

wd = pluginHost.getWorkingDirectory()
streamsFile = wd + "streams.dep"
pointerFile = wd + "D8 pointer.dep"
outputFile = wd + "output.dep"
args = [streamsFile, pointerFile, outputFile]
pluginHost.runPlugin("StreamOrder", args, False)

This is a Groovy script also using this tool:

def wd = pluginHost.getWorkingDirectory()
def streamsFile = wd + "streams.dep"
def pointerFile = wd + "D8 pointer.dep"
def outputFile = wd + "output.dep"
String[] args = [streamsFile, pointerFile, outputFile]
pluginHost.runPlugin("StreamOrder", args, false)