Guest User | Sign In

Knowledge Base

GetData Function

The GETDATA function can be used to retrieve data for a security different from the chart displayed on the screen.

NOTE: For the Pascal Programming Module version please see here.

Here's an example using the custom bar colour scheme to colour the bars of the S&P500 index red when the VIX volatility index is above its 22 day moving average. The GetData function is used to retrieve the data for the VIX (variable V1) and then V1 is nested in a moving average function MA() (note: VIX data requires access to the CBOE Index exchange):

V1 > MA(V1, BARS=22, CALC=Close)

Click on the GETDATA text in the script editor window and type the required symbol in the Code property and select it from the list:


Here's a variation of the above which could be used on a Show Bar or Signal Test on the SPX signalling when the VIX crosses above 20:

V1 CrossesAbove 20

Please Wait!

Please wait... it will take a second!