Using Chart Continuation Settings in RTD Formulas

RTD formulas for chart types and studies can include the same parameter settings used in your CQG continuation charts. In the RTD formula the continuation parameters are entered in the “time interval" field and the choice to equalize the closes is entered in the “equalize closes" field.

In the RTD formula below the symbol is "EP" and the formula calls for the closing price for today’s daily bar (indicated by "D"). No continuation setting is applied. The choice to equalize closes is set to “False”, however, this setting in this example does not matter as there is no continuation setting applied. The RTD formulas is pulling data for All sessions and returns the price as a decimal ("T").

= RTD("cqg.rtd",,"StudyData","EP", "Bar", "", "Close","D","0","All","","","False","T")

If you wanted to use “Standard-Rollover at Expiration, then replace "D" with "DC" and if you wanted to equalize closes the replace "False" with "True."

= RTD("cqg.rtd",,"StudyData","EP", "Bar", "", "Close","DC","0","All","","","True","T")

Now, when the contract rolls at expiration Excel will automatically pick up the new symbol. This also applies when pulling in historical data. To pull in historical data replace the "0" with "-1" or "-2", etc. There is a limit for pulling historical data, which is 300 daily bars from today.

To use the same contract for the continuation chart (i.e., always use the September contract), then use "DDC" with the symbol for September.

= RTD("cqg.rtd",,"StudyData","EPU", "Bar", "", "Close","DDC","0","All","","","True","T")

If you wanted to see continuation market data using “Adjusted – rollover N days prior to expiration and optionally Equalize closes” setting then use "JDC" with a negative number for the N days prior to expiration. The RTD formula below rolls the contract 20 days before the expiration.

= RTD("cqg.rtd",,"StudyData","EP", "Bar", "", "Close","JDC-20","0","All","","","True","T")

Again, you can equalize closes using "True" or not equalize closes by using "False".

To pull in continuation market data based on the “Active – rollover with trading activity and optionally Equalize closes” then use "ADC" for the time interval setting.

= RTD("cqg.rtd",,"StudyData","EP", "Bar", "", "Close","ADC","0","All","","","True","T")

For more information about chart setting, please read the Help file.

Download a sample RTD Excel file for pulling historical data. Enter the continuation setting into the “Chart Time Frame” cell and True or False in the “Continuation" cell to equalize closes or not.

Microsoft Excel is a registered trademark of Microsoft Corporation in the United States and/or other countries.