Protect

Top  Previous  Next

This dollar command freezes all values of the named parameters not allowing modification but still allowing their use in model calculation (.. commands when models are set up) in a privacy setting.

 

$protect item1 item2

or

$protect all

Notes:

A list of items follows $protect and results in multiple items being protected.
While the statement example above lists two items one, two or many more can be listed.
The word ALL can also be used to protect all items.
Appendix H of the GAMS Users Guide elaborates.
The protection only takes effect in the restart files.