Skip to content

Model Operation

The State Model is structured to perform one of four (4) interrelated activities:

  • Base Flows
  • Simulate
  • Report
  • Data Check

For a description of each option, see Section 3.3 of this documentation. The model can be executed using either the StateMod Graphical User Interface available from the CDSS website or via a command line argument. If a command line argument is used, navigate the command prompt to the location of the StateMod Model, and enter the model name, file name, and options as follows. Note that a StateMod executable needs to be in the same directory as the StateMod model files:

statemod [file] [options]

where:

statemod = base name of StateMod executable, such as statemod or StateMod_Model_15. file = base file name of the simulation, such as cm2015.

Note the order of the [file] and [options] matters.

Option1 Description
-v or -version Print the program version
-u or -update Print recent updates
-base or -baseflow Perform baseflow option
-basex or -baseflowx Perform baseflow option for ungaged areas only. Note: This option assumes gaged flows are natural flows.
-sim or -simulate Perform simulate option with standard reports
-simx or -simulatex Perform simulate option without standard reports
-rep or -report [options2] Perform report option
-chk or -check Perform data check option

1 If omitted, the PC version of the model defaults to requesting the desired option from the screen, while the Unix version prints an error message.

Except for the -report option, each of the above requests are straight forward and require only one command line argument. The -report option allows for one or two additional parameters in order to request the desired report and, as appropriate, desired station without requiring data from the screen by the user. Note, except for the standard output request (-std), the argument name is the same as the output file requested. Following are examples of the report option with second and third parameters supplies:

Argument1 Result
-report -xnm Detailed node accounting for all years and Detailed node accounting average
-report -xwb Water Balance
-report -xwr Water Right List sorted by basin rank
-report -xdg [-station id] Direct Diversion, Instream Diversion and Gage graph file
-report -xrg [-station id] Reservoir graph file
-report -xwg [-station id] Well graph file
-report -xdc Diversion comparison file
-report -xrc Reservoir comparison file
-report -xwc Well comparison file
-report -xsc Stream flow gage comparison file
-report -xcu Diversions by ditch formatted for the CU model
-report -xst Standard diversion (*.xdd) and reservoir (*.xre) output
-report -xsp Special parameter report2.

1 If omitted, the PC version of the model defaults to request the desired option from the screen, while the Unix version prints an error message.

2 For the special parameter report the output type (e.g. diversion, reservoir, well, stream gage or All) and parameter (e.g. River_Outflow) must be specified in the output request file.