Specify a set of CMD statements to be invoked as a procedure

Syntax


procedure <procedure name>

   <list of CMD script statements>

end

Description


The PROCEDURE keyword is used to denote a set of statements in a CMD file which can be invoked by simply using a unique name given to the collection of statements.  This is useful when a specific set of statements will be invoked repeatedly throughout a CMD script, e.g., when plotting a fixed set of output quantities.

Example


procedure run_and_plot_outputs

   prepare t x y z

   start

   plot x y x

end


! Statements to set parameters in various ways…


run_and_plot_outputs