Drawing indicatorDataseries line in cBot.

Created at 18 Jul 2022, 17:52
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!
SH

Shares4UsDevelopment

Joined 14.10.2018

Drawing indicatorDataseries line in cBot.
18 Jul 2022, 17:52


How do I get this code to draw an IndicatorDataSeries line. ( it;s a Robot, Not an Indiator!)
The alternative is drawing tons of Trendlines and not very appealing to me..

using cAlgo.API;
using cAlgo.API.Indicators;

namespace cAlgo.Robots
{
    [Robot(AccessRights = AccessRights.None)]
    public class NewcBot5 : Robot
    {
        [Output("Main", LineColor = "yellow")]
        public IndicatorDataSeries Result { get; set; }

        protected override void OnStart()
        {
        }

        protected override void OnTick()
        {
            Result[Bars.Count-1]= (Bars[Bars.Count-1].Open + Bars[Bars.Count-1].Close)/2;
        }
    }
}

@Shares4UsDevelopment
Replies

PanagiotisCharalampous
19 Jul 2022, 08:21

Hi there,

It is not possible at the moment.

Best Regards,

Panagiotis 

Join us on Telegram and Facebook

 


@PanagiotisCharalampous