How to get data from custom indicator?

Created at 15 Jul 2016, 16:36
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!
BR

brianchan661

Joined 15.07.2016

How to get data from custom indicator?
15 Jul 2016, 16:36


I have download some custom indicator and want to create a cBot based on it.

How can I can the data from the corresponding custom indicator? 


@brianchan661
Replies

... Deleted by UFO ...

brianchan661
16 Jul 2016, 14:33

RE:

lucian said:

/api/guides/indicators#el8

public class SchaffTrendCycle : Indicator
    {
        [Parameter("MA Short", DefaultValue = 23, MinValue = 1)]
        public int MAShort { get; set; }

        [Parameter("MA Long", DefaultValue = 50, MinValue = 1)]
        public int MALong { get; set; }

        [Parameter("Cycle", DefaultValue = 10, MinValue = 1)]
        public int Cycle { get; set; }

        [Output("Schaff Trend Cycle", Color = Colors.DarkOrchid, Thickness = 2)]
        public IndicatorDataSeries ST2 { get; set; }

................

.................

}
 protected override void OnStart()
        {
            stcIndicator = Indicators.GetIndicator<SchaffTrendCycle>(23, 50, 10);
        }

        protected override void OnBar()
        {
            Print(stcIndicator.ST2[0]);
        }

I tried to create the instance but seem fail, they are not printing the result but "non number"

 


@brianchan661

... Deleted by UFO ...