Command Program

Once you have created and compiled a model, you may wish to examine certain aspects of it in greater detail. The Command Program allows you to perform special tasks, including debugging models, viewing probabilities for events of interest, and examining values for specific paths and events. It is especially useful if you have large models. You can add a Command Program by right mouse clicking in the Workspace Manager, and then selecting Add to Workspace | Command or going to Home | Workspace | Add | Command Program.

Essentially, the Command Program allows you to view any number in a model. This includes values, probabilities, series, array elements, and expressions. The Command Program also lets you change any value in a model. These two capabilities provide a very powerful and flexible environment for testing and debugging. A Command Program is similar to a Program window.

If you wish to examine the probability distribution of a particular event, the Command Program eliminates the need for searching the program code or the influence diagram for that event. By typing the name of the event into the Command Program and executing the command by selecting Command | Execute | Run, the probability distribution for that event is printed to the Log. If you wish to examine a probability or outcome of an event given that its influencing events are in certain states, you may do so by setting the event states, typing the name of the variable of interest into the command window, and selecting Command | Execute | Run. For example, you may examine the final outcome of a particular path of your model by setting all events to appropriate states and executing the command.

The Command Program can be used for debugging by allowing you to examine the behavior of variables under different conditions. For example, you can verify that the outcome value Profits increases when the variable Revenues is in state High, and that it decreases when the variable Costs is in state High.

Another application of the Command Program is to change data temporarily in your model without actually altering the original model. For example, you may wish to examine the effect on the final outcome of a change in a certain variable by assigning a new value to that variable in the Command Program.

Remember that commands are always executed on the most recently compiled DPL model.

The Command Program vs. Sensitivity Analysis

Both the Command Program and Rainbow Diagrams enable you to conduct further analyses on your decision model. The two differ in the way they control variables. The Command Program allows you to modify several values and events at once before analyzing a model. Rainbow Diagrams allow you to modify one variable over a range of values. Also, the original value of the sensitivity variable is restored following the sensitivity run. See Rainbow Diagram.

Versions: DPL Professional, DPL Enterprise, DPL Portfolio

See Also

Changing Values

Displaying Probability Distributions

Changing Probability Distributions

Events and Values with the Same Name

Working with Command Statements

Working with Program Files

Editing DPL Programs