ICE Data Services -

AGet.xtl() Advanced GET Studies

Returns the series or values of the GET XTL study.
The XTL (eXpert Trend Locator) is a proprietary study Tom Joseph developed that uses a statistical evaluation of the market that can tell the difference between random market swings (noise) and directed market swings (trends).
AGet.xtl( Length [, sym() | inv() ][, BarIndex ] )
Parameter: Description: Default:
Length An integer which represents the number of bars used to calculate the study.


n/a sym() | inv() [Optional]  Function of sym() or inv() to determine symbol/interval source for the study.


Base sym/int BarIndex [Optional]  Bar index of series to retrieve.


Return Value(s)
Returns a Series Object when
nBarIndex is not specified. It consists of the set of constants shown below.
Returns a single value when nBarIndex is specified from the set of constants shown below.
A set of constants:
Only available in versions 11.8 or later.
Code Example
Creating and Using Series Example:
var bInit = false;var xSer = null;setPriceStudy(true);setColorPriceBars(true);function main(){        if(bInit == false){        xSer = AGet.xtl(35);        bInit = true;    };    var nSer = xSer.getValue(0);        if (nSer == null)        return;    if (nSer == UP_TREND) setPriceBarColor(Color.RGB(0x00,0x91,0xFF));    if (nSer == DOWN_TREND) setPriceBarColor(Color.RGB(0xFF,0x00,0x00));    if (nSer == NEITRAL) setPriceBarColor(Color.RGB(0xA0,0xA0,0xA4));}      
See Also
Advanced GET Study Functions