API 3.7 MarketData.GetSeries replacement?

Created at 05 Feb 2020, 12:00
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
FI

firemyst

Joined 26.03.2019

API 3.7 MarketData.GetSeries replacement?
05 Feb 2020, 12:00


With API 3.7:

MarketData.GetSeries

is now obsolete, but there's no suggested replacement? How do we now get a different symbol and timeframe's data other than the currently viewed chart? Eg, if I'm viewing the US30 on an M1 chart, and want to get data from the GER30 M1, how do we now do this? It used to be MarketData.GetSeries(_symbol, _timeFrame);

Also, when will the online API guide be updated? I can't find the new "bars" interface in it.

Thank you.


@firemyst
Replies

firemyst
05 Feb 2020, 12:02

RE:

firemyst said:

With API 3.7:

MarketData.GetSeries

is now obsolete, but there's no suggested replacement? How do we now get a different symbol and timeframe's data other than the currently viewed chart? Eg, if I'm viewing the US30 on an M1 chart, and want to get data from the GER30 M1, how do we now do this? It used to be MarketData.GetSeries(_symbol, _timeFrame);

Also, when will the online API guide be updated? I can't find the new "bars" interface in it.

Thank you.

I just found it.

I believe it's now:

MarketData.GetBars(Bars.TimeFrame, _symbol);

However, if I'm wrong or there's something else I should be using, please let me know.

Thanks!


@firemyst

... Deleted by UFO ...

firemyst
09 Feb 2023, 09:59

RE: RE: RE:

ctid1531384 said:

firemyst said:

firemyst said:

With API 3.7:

MarketData.GetSeries

is now obsolete, but there's no suggested replacement? How do we now get a different symbol and timeframe's data other than the currently viewed chart? Eg, if I'm viewing the US30 on an M1 chart, and want to get data from the GER30 M1, how do we now do this? It used to be MarketData.GetSeries(_symbol, _timeFrame);

Also, when will the online API guide be updated? I can't find the new "bars" interface in it.

Thank you.

I just found it.

I believe it's now:

MarketData.GetBars(Bars.TimeFrame, _symbol);

However, if I'm wrong or there's something else I should be using, please let me know.

Thanks!

So how do we do it?

All I want is to have the Weekly RSI number there, So i can have 

if (Week RSI > 70)

{dont trade etc

Dont even want it from a different symbol, Just the same one thats on the cbot chart.

 

John.

 

 

Get your Bars / Market Series in the time frame you want, and then create a new Relative Strength Index object with that bars/market series as the first parameter.

Example is right here on this site:

 


@firemyst