REFORMULATE directive

Modifies a formula or an expression to operate on a different set of data structures.


Options

OLDFORMULA = formula or expression
Original formula or expression

NEWFORMULA = formula or expression
New formula or expression, modified to operate on the new structures


Parameters

OLDSTRUCTURE = identifiers
Data structures in the OLDFORMULA to be replaced in the NEWFORMULA

NEWSTRUCTURE = identifiers
Identifier of the new data structure to replace each OLDSTRUCTURE


Description

The REFORMULATE directive allows you to modify a formula or expression to operate on a different set of data structures. The original formula or expression is specified by the OLDFORMULA option, and the new formula or expression is specified by the NEWFORMULA option. If NEWFORMULA is not specified, the new formula or expression replaces the old one in OLDFORMULA. The data structures to be replaced in OLDFORMULA are listed by the OLDSTRUCTURE parameter, and the corresponding data structures for NEWFORMULA are provided by the NEWSTRUCTURE parameter.

   The example below shows how you could convert formula A*B (stored in Old) into formula Y*Z (stored in New).

FORMULA [VALUE=A*B] Old

REFORMULATE [OLDFORMULA=Old; NEWFORMULA=New]\

            OLDSTRUCTURE=A,B; NEWSTRUCTURE=Y,X

 

Options: OLDFORMULA, NEWFORMULA.

Parameters: OLDSTRUCTURE, NEWSTRUCTURE.