Clearing IndicatorDataSeries

Created at 27 Jan 2016, 23: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!
whis.gg's avatar

whis.gg

Joined 31.08.2015

Clearing IndicatorDataSeries
27 Jan 2016, 23:00


Hi,

Is it possible to clear or null IndicatorDataSeries? It acts as array of values but I couldn't figure out how to clear it or null specified index.


@whis.gg
Replies

whis.gg
27 Jan 2016, 23:11

Or if I could set length of that array. I would solve my problem as well.


@whis.gg

Spotware
27 Jan 2016, 23:53

Dear Trader,

Please have a look at the CreateDataSeries() method.


@Spotware

vschipplock
10 May 2017, 03:18

"null specified index"

Hi tmc.

did you get an answer on how to clear it for a specified index? I looked at the CreateDataSeries page and it doesn't seem to answer that part.

I don't want to re-init the whole array, I just want to assign an empty value to a specific index but I can't find any details on it. "null" doesn't work and there is no value for "nothing" or "empty" that I can find. When I assign it 0 the indicator uses that actual value.

thanks,

V


@vschipplock

whis.gg
10 May 2017, 03:24

Hi, I don't think I got an answer I was looking for. Anyway, here is how to assing an empty value to the IndicatorDataSeries.

series[index] = double.NaN;

 


@whis.gg

vschipplock
10 May 2017, 04:19

RE:

tmc. said:

Hi, I don't think I got an answer I was looking for. Anyway, here is how to assing an empty value to the IndicatorDataSeries.

series[index] = double.NaN;

 

I knew it had to be simple, just couldn't find it anywhere. Thanks for taking the time to help, appreciate it.

V


@vschipplock