Skip to content

StateDMI / Command / SetStreamGageStation


Overview

The SetStreamGageStation command (for StateMod) sets data in existing stream gage stations or adds a new stream gage station.

Command Editor

The following dialog is used to edit the command and illustrates the command syntax.

SetStreamGageStation command editor

SetStreamGageStation Command Editor (see also the full-size image)

Command Syntax

The command syntax is as follows:

SetStreamGageStation(Parameter="Value",...)

Command Parameters

Parameter             Description Default          
ID
required
A single stream gage station identifier to match or a pattern using wildcards (e.g., 20*). None – must be specified.
Name The name to be assigned for all matching stream gage stations. If not specified, the original value will remain.
RiverNodeID The river node identifier to be assigned for all matching stream gage stations. If not specified, the original value will remain.
DailyID The daily identifier to be assigned for all matching stream gage stations. If not specified, the original value will remain.
IfNotFound Used for error handling, one of the following:
  • Add – add the stream gage station if the ID is not matched and is not a wildcard
  • Fail – generate a failure message if the ID is not matched
  • Ignore – ignore (don’t add and don’t generate a message) if the ID is not matched
  • Warn – generate a warning message if the ID is not matched
Warn

Examples

See the automated tests.

The following example command file illustrates the commands used to read stream gage stations from the network and create a StateMod file:

StartLog(LogFile="ris.commands.StateDMI.log")
# ris.commands.StateDMI
#
# StateDMI command file to create streamflow station file for the Colorado River
#
#  Step 1 - read streamgages and baseflows ids from the network file
#
ReadStreamGageStationsFromNetwork(InputFile="..\Network\cm2005.net",IncludeStreamEstimateStations="True")
#
#  Step 2 - read baseflow nodes names from HydroBase,
#           fill in missing names from the network file
#
FillStreamGageStationsFromHydroBase(ID="*",NameFormat=StationName,CheckStructures=True)
FillStreamGageStationsFromNetwork(ID="*",NameFormat="StationName")
#
#  Step 3 - set streamgage station to use to disaggregate monthly baseflows to daily
#
#  add set daily pattern gages for WD 36
SetStreamGageStation(ID="36*",DailyID="09047500",IfNotFound=Warn)
...many similar commands omitted...
#
#  Step 4 - create streamflow station file
#
WriteStreamGageStationsToStateMod(OutputFile="..\StateMod\cm2005.ris")
#
# Check the results
CheckStreamGageStations(ID="*")
WriteCheckFile(OutputFile="ris.commands.StateDMI.check.html")

Troubleshooting

See the main troubleshooting documentation

See Also