The following examples show you how to set up RTD links with live data in Microsoft Excel.

However, in most cases it is easier and more comfortable to simply use the Copy command from your TeleTrader WorkStation document to create a live RTD link (see below). An RTD link for the displayed symbol or a list of symbols is then created automatically. The RTD links can then be inserted into a Microsoft Excel table with the function Insert or with the key combination Ctrl + V.

In order to use RTD when copying data from TeleTrader WorkStation documents to your spreadsheet software, you have to set the DDE/RTD format under Tools > Options > Price Page to Microsoft Office RTD (see Price Page Settings).

If you want to use historical data in your spreadsheet, or a combination of historical and current data (for example, the last 10 ticks of a symbol), you have to use another type of RTD link: See Setting up an RTD Link with Historical Data.

To copy live, updating quote data to Microsoft Excel

▪       Open a price page, watch list, market depth, options matrix or time and sales document in TeleTrader WorkStation that shows the data that you want to copy. See also Opening Symbols and Adding and Removing Columns.

▪       Select all cells that you want to copy to Microsoft Excel. You can highlight them with the mouse, or select complete rows or columns (see also Selecting Rows or Columns of a Price Page).

▪       Right-click on the selected cells and choose Copy.

Note             When you want to copy data from a market depth document, right-click in the summary view of the market depth document and choose Copy to copy all data.

▪       Open a Microsoft Excel spreadsheet.

▪       Paste the data that you have copied into Excel. For example, you can use the shortcut Ctrl + V.

▪       The data that you have copied will now be displayed in the Excel spreadsheet. It will be updated whenever new ticks arrive.

Note             By default, the column headings of the price page are copied along as well. You can disable this setting under Tools > Options > Price Page (see Price Page Settings).

To request live quote data manually in Microsoft Excel (example)

▪       Open a Microsoft Excel spreadsheet.

▪       In the cell where you want the data field to appear, type (or copy) the following formula:

=RTD("ProfRTD";;"Live";"{949843},Last")

▪       The requested data will appear in the Microsoft Excel cell. The request above will for example fetch the Last price of the EURUSD currency pair.

Syntax for RTD Links to Live Data

In your Microsoft Excel spreadsheet, certain formulas are used to create the RTD links. If you use the Copy command, all RTD links are created automatically for you. If you set up the links manually, you have to use the following syntax to request live quote data:

=RTD("ProfRTD";;"Live";"<Symbol>,<Field>")

Note             The character you have to use for separating the different arguments of the RTD function (shown as a semicolon ; above) depends on the regional configuration of your operating system. Under Windows, you can change this configuration in the Control Panel.

Symbol

Internal identification of the symbol. You can either use the symbol identification number (for example {829802} ) or its unique name (for example MSFT_1061SPC).

To find out the identification of a symbol, click in the row of the symbol in a price page and press F2. Identification number and unique name can also be displayed in the price page columns TID and TUN or in the Chart Properties dialog for a symbol.

You can also use the Lookup command to search for a symbol ID within Excel (see Searching for Symbols with RTD).

Field(s)

Name of the data field(s) that should be retrieved. See Available Field Names.

Market Depth Fields

For market depth data, the following field names can be used – the number in square brackets signifies the depth level, starting with 0:

 

MDBidSize[depth_level]

MDBidCount[depth_level]

MDBid[depth_level]

MDAsk[depth_level]

MDAskSize[depth_level]

 

Note             It is not possible to display market depth data from NASDAQ via RTD.

 

Example for retrieving the Bid price at the third depth level:

=RTD("ProfRTD";;"Live";"{458812},MDBid[2]")

VWAP Fields

The Volume Weighted Average Price (VWAP) of a stock over a specific market period is defined as the average price paid per share during that period (price of each transaction in the market weighted by its volume). It is calculated from the volumes and prices of all trades during a certain period of time. See also Adding, Removing and Customizing the VWAP Columns.

You can retrieve VWAP data with an RTD link. The VWAP data is calculated for a certain time period, according to your request. Use the following field syntax:

 

VWAP(Type,DateTimeF,DateTimeT,VolF,VolT,PriceF,PriceT)[OutputName]

Type                        Time period used for VWAP calculations: This can be D (Daily), LH (Last Hour), C (Custom), N (None) or F (Freeze).

DateTimeF/T        Begin and end date and time of a custom time period (C) in ISO format YYYY-MM-DDThh:mm:ss

VolF/T                    Lower and upper boundaries for the volume range (optional)

PriceF/T               Lower and upper boundaries for the price range (optional)

OutputName          Defines the VWAP value that should be returned: Price, StdDev, TotalVol, AvgVol, NumTicks, DateF, DateT, TimeF, TimeT, VolF, VolT, PriceF, PriceT

 

Examples for retrieving VWAP data:

=RTD("ProfRTD";;"Live";"{458757},VWAP(LH)[StdDev]")

=RTD("ProfRTD";;"Live";"{458757},VWAP(C,2010-04-08T22:00:00,2010-04-09T10:00:00,0,100000,40.00,45.00)[Price]")

Study Fields

TeleTrader WorkStation offers a large amount of analysis tools (studies) to calculate indicators and signals. Depending on the study, one or more columns are necessary for displaying the study data for a symbol. You can choose the data compression that should be used for the study (Daily, Weekly, Monthly, Intraday or Tick by Tick data) and adapt the study's parameters. For a list of all available studies and their parameters, see the Study Reference.

To retrieve study data with an RTD link, use the following field syntax:

 

AT(FunctionName,{Base1Name:Base1Symbol}...{BaseXName:BaseXSymbol},Compression,{FID1}...{FIDn},{Param1Name:Param1Value}...{ParamXName: ParamXValue},TickOrBar,LastNBars)[OutputEntity:OutputProperty]

 

FunctionName      Name of study function (for example movs for Moving Average Simple)

 

Base1Name             Usually there is only one base symbol which is called Source. For some studies that have more than one base symbol, the appropriate names for the different bases are listed in the Study Reference.

 

Base1Symbol        Symbol identification number of the base symbol, for example {829802}.

 

Compression        Data compression of the time series that is used to calculate the study values. Possible values are: Daily, Weekly, Monthly, x Minutes (for Intraday compressions – possible values for x: 1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60), x Hours (for Intraday compressions – possible values for x: 2, 3, 4, 6, 8, 12), Tick by Tick.

 

FID1          Price that is used for calculation of the study. Possible values are: Open, Close, High, Low, Volume, OI
Some studies use all price values; in that case, you have to use {All}.

 

Param1Name          Name of the study's first parameter as listed in the Study Reference, for example period.
If a study has more than one parameter, they all have to be listed.

 

Param1Value   Value assigned to the study's first parameter, for example 21.

 

TickOrBar             Define whether the study should be recalculated on each new tick (tick) or on each new bar (bar). Use bar if you are experiencing performance problems.

 

LastNBars             Time region that is used for calculating the study, for example 21. This setting influences the amount of historical time series data that is downloaded for the base symbol The appropriate setting often depends on the currently set study parameters, such as the period of a Moving Average.
If you add too little history, the study might not be calculated (leading to an empty value in the study column); If you add too much history, this can affect performance.

 

OutputEntity      Name of the study's output entity, usually similar to the function name, for example MovS.

 

OutputProperty Name of the study's output property (Upper, Lower, Price etc.). In case of Line studies, OutputProperty is fixed to Value since there is only one property.

 

Example for retrieving study data  with one result ("Line"):

=RTD("profrtd";;"Live";",AT(movs,{Source:{459237}},Daily,{Close},{period:21}{shift:0},tick,21)[MovS:Value]")

 

Example for retrieving study data with multiple results ("Multiple Lines", "Areas"):

=RTD("ProfRTD";;"Live";",AT(boll,{Source:{459237}},Tick by Tick,{High},{period:20}{deviation1:2}{deviation2:-2},tick,20)[Boll:Upper]")

=RTD("profrtd";;"Live";",AT(boll,{Source:{459237}},Tick by Tick,{High},{period:20}{deviation1:2}{deviation2:-2},tick,20)[Mid:Value]")

=RTD("profrtd";;"Live";",AT(boll,{Source:{459237}},Tick by Tick,{High},{period:20}{deviation1:2}{deviation2:-2},tick,20)[Boll:Lower]")

 

Example for retrieving study data with markers – values will only be displayed if the marker appears on the current bar  ("Candlestick Patterns", "Buy/Sell Signals"):

=RTD("profrtd";;"Live";",AT(atr_trail,{Source:{458822}},60 Minutes,{All},{TrailTypeMod:True}{Period:21}{Factor:1.5}{InitialMonth:1}{InitialDay:1}{InitialYear:2009}{FirstTrade:1}{ShowTraderMarks:True}{ShowLine:True},tick,142)[BuySell:Price]")

=RTD("profrtd";;"Live";",AT(atr_trail,{Source:{458822}},60 Minutes,{All},{TrailTypeMod:True}{Period:21}{Factor:1.5}{InitialMonth:1}{InitialDay:1}{InitialYear:2009}{FirstTrade:1}{ShowTraderMarks:True}{ShowLine:True},tick,142)[BuySell:Text]")

=RTD("profrtd";;"Live";",AT(atr_trail,{Source:{458822}},60 Minutes,{All},{TrailTypeMod:True}{Period:21}{Factor:1.5}{InitialMonth:1}{InitialDay:1}{InitialYear:2009}{FirstTrade:1}{ShowTraderMarks:True}{ShowLine:True},tick,142)[BuySell:Direction]")

 

Example for retrieving study data with multiple base symbols:

=RTD("profrtd";;"Live";",AT(indCorrelation,{Source1:{459237}}{Source2:{458757}},Daily,{Close}{Close},{period:5}{shift:0},tick,5)[Corr:Value]")

 

In case of study fields that exceed Microsoft Excel's limit of 200 characters, the field can be broken into several parts of formula where each part begins with AT+.

 

Example for formulas that exceed maximum number of characters:

=RTD("profrtd";;"Live";",AT(tmv,{Source:{458757}},Daily,{All},{KeltnerPeriod:20}{ShowVolatilityAndTrend:True}{UseLindaRaschkeKeltner:False}{ADXPeriod:10}{SMAPeriod:8}{ShowTrendStrengthAndDirection:True}{CCIPeriod:13}{UpperL)";"AT+(evel:100}{LowerLevel:-100}{ShowMomentumAndTrend:True}{ShortTermVolumePeriod:1}{LongTermVolumePeriod:20}{VolumeOscSpikeThreshold:50}{ShowVolumeOscillationExtremes:True},tick,131)[KeltnerMidLine:Value]")

Learn more:

Tips and Examples for Retrieving Live Data