spread-ratio indicator for TS

pboyles

Legendary member
Messages
8,046
Likes
1,306
I believe there is now an indicator in TS called 'spread-ratio'. Can this indicator plot the spread between two different instrument eg Dax and Eurostoxx? I've been looking into this lately but it seems it may already be incorporated into TS. I dont use TS but do use easylanguage indicators in another platform.
 
Wouldn't you simply do a division on closing mid for each bar? I don't use easylanguage either, but if you're getting data in the form of OHLC bars, you do need to be very careful about what you take from each bar, because spreads need to be calculated on contemporaneous quotes and too much info is lost in OHLC bars. It would be different if you received a full tick history.

With 1m bars you can calculate a 1m line graph using closing mid (since you know the prices are contemporaneous). Or, you could use the opening prices (again, contemporaneous).

I expect this is why the ratio is plotted as a line rather than bars, as the graphics don't download full tick history.
 
Wouldn't you simply do a division on closing mid for each bar? I don't use easylanguage either, but if you're getting data in the form of OHLC bars, you do need to be very careful about what you take from each bar, because spreads need to be calculated on contemporaneous quotes and too much info is lost in OHLC bars. It would be different if you received a full tick history.

With 1m bars you can calculate a 1m line graph using closing mid (since you know the prices are contemporaneous). Or, you could use the opening prices (again, contemporaneous).

I expect this is why the ratio is plotted as a line rather than bars, as the graphics don't download full tick history.

I was going to look at the code to see how it calculated the spread. Currently I am using excel to backtest spread on the close of 1 minute bars.

I can export tick history from my charts but the problem then is matching up to the two different instruments as the tick may occur at different times in each one.
 
Top