GETLOCALVARIABLE

Purpose:

Returns the value of a local variable.

Syntax:

GETLOCALVARIABLE("name", element)

"name"

-

A string. The name of the local variable.

element

-

Optional. An integer, the array index if the variable is a series or array.

Example:

setlocalvariable("A", {25, 41, 33});
curr * getlocalvariable("A")

 

multiplies the series in the current window (curr) by the local variable A.

Remarks:

SETLOCALVARIABLE and GETLOCALVARIABLE  are very useful for creating and referencing an arbitrary number of generic local variables in an SPL function.

 

GETLOCALVARIABLE and SETLOCALVARIABLE can be abbreviated GETLOCAL and SETLOCAL

See Also:

DELALLVARIABLES

DELVARIABLE

SETLOCALVARIABLE

SETVARIABLE

VARS