Use of Constants
Most of the macro function parameters can take numeric constants or expressions evaluating to a numeric constant (macro functions operating on strings can take string constants). In macro functions performing record-by-record operations, using a constant is equivalent to specifying a column containing that constant value in each row. Essentially, when a constant and a cell or column range are provided as input parameters, the constant is expanded to same dimensions as the cell or column range. Any column containing a single cell used as input in a macro function is considered a constant.
Some macro functions can take ASCII text strings as well as numerical constants. Parameters that can accept both numeric constants and ASCII text strings are noted in the "Parameters" section of each macro function.
Examples are provided in the following table.
The constant 2 is interpreted as a column containing the same number of rows as the column V1, with each row containing the constant 2. The column V2 will contain each value of V1 multiplied by 2.
The constant "ing" is interpreted as a column containing the same number of rows as the column V1, with each row containing the constant "ing". The column V2 will contain each of the text strings in V1 concatenated with "ing".
The expression AVG(V1:V3) evaluates to a constant value, say x. The constant xis interpreted as three columns containing as many rows as the shortest column of V1, V2, or V3. Each cell contains the constant x. The output columns, V4-V6, will contain the values from columns V1-V3 divided by x.
The constant 2 is interpreted as a cell range with 11 rows, each containing the value 2.