Is this cBot too good to be true?!?1?

Created at 01 Jan 2018, 15:38
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!
DR

Drummond360

Joined 22.12.2017

Is this cBot too good to be true?!?1?
01 Jan 2018, 15:38


Hi All (and a happy new year..!),

Over the last few weeks I've built what seems to be a fantastic cBot... 

It's a scalper trading on 1 min charts and as you can see in the inages below it places a lot of trades...

Each of the results below are from a £10K starting balance and the same settings were used throughout, no optimizing or curve fitting for each pair...

I guess my question is whether cAlgo can cope with 4 instances scalping on a 1 min chart with most of the logic onTick?!?

 

 


@Drummond360
Replies

Drummond360
02 Jan 2018, 13:57 ( Updated at: 21 Dec 2023, 09:20 )

Here's a shorter test with stats:

 


@Drummond360

PanagiotisCharalampous
02 Jan 2018, 14:27

Hi Drummond360

I guess my question is whether cAlgo can cope with 4 instances scalping on a 1 min chart with most of the logic onTick?!?

 The answer to this question is directly related to the hardware you are running your cAlgo on. I would encourage you to test your cBot on the hardware you are planning to use using a demo account and if the performance does not satisfy you, make the necessary adjustments e.g. upgrade your computer or VPS, check your network connection, optimize your code etc.

Best Regards,

Panagiotis


@PanagiotisCharalampous

eddydarang
02 Jan 2018, 16:20

Pour repondre a votre question je devrais savoir quel  Cbot  que vous avez utilise


@eddydarang

thriscio
03 Jan 2018, 00:09

I think you need to do check-up of margin on your OnTick() Method.

Yes it seems to be a good algo, but I'm pretty it fells below 500% margin level in a matter of time.

Can you post the code 


@thriscio

Drummond360
03 Jan 2018, 15:30

Thank you for commenting....

After running this live yesterday I'm working on restricting how active it is...

It's now much smoother and only allows 2 positions to be open at once...

I'll crack on with de-bugging and share the code when it's a little less embaracing!!

 


@Drummond360

markae
30 Jan 2018, 16:32

Any updates on this?

 


@markae

Drummond360
30 Jan 2018, 16:56

Yes, I dissproved these results, here's a quick summary;

These results are backtested on 1 minute bars. As this form of backtesting only respects the open price the back test assumed that my trailing stop was always honoured at the 5 pip level it was set to, however Tick data testing showed that my trailing stop was being hit well before the next bar opened and actaully returning a loss more often than a profit...

I'll be testing everything with Tick data from now on!

Drummond

 


@Drummond360

sifneos4fx
31 Jan 2018, 10:28

RE:

Dude, that cBot is awesome, what is the strategy? Stochastics and MA50 and MA100? Do you close on specific PIPs or on specific indicator value?

 

Drummond360 said:

Yes, I dissproved these results, here's a quick summary;

These results are backtested on 1 minute bars. As this form of backtesting only respects the open price the back test assumed that my trailing stop was always honoured at the 5 pip level it was set to, however Tick data testing showed that my trailing stop was being hit well before the next bar opened and actaully returning a loss more often than a profit...

I'll be testing everything with Tick data from now on!

Drummond

 

 


@sifneos4fx

Drummond360
31 Jan 2018, 10:48

Thanks, yes Stochastics and RSI... Entering with trailing stop orders....

But the entry doesnt really matter... As mentioned in my last post the trailing stop loss was showing false profit, once tested with tick data it all fell apart....


@Drummond360

Drummond360
31 Jan 2018, 11:56 ( Updated at: 21 Dec 2023, 09:20 )

If you liked those results check out this little weapon!

 


@Drummond360

sifneos4fx
31 Jan 2018, 12:49 ( Updated at: 21 Dec 2023, 09:20 )

RE:

This is a prototype of scalping Bot.

Rules:

  • Timeframe: 1 Minute. May also work on 5 minutes 
  • Stochastic K% < 20 and Stochastics K% > Stochastics D%
  • Stochsastic K% should rising
  • RSI should rising
  • Close on Stochsatics K% > 80

Play with parameters ans let me know what you think.

 

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo
{
    [Robot(TimeZone = TimeZones.CentralEuropeanStandardTime, AccessRights = AccessRights.None)]


    public class NewcBot : Robot
    {
        private MovingAverage EMA_Fast;
        private MovingAverage EMA_Slow;
        private StochasticOscillator Stochastics;
        private RelativeStrengthIndex RSI;

        protected override void OnStart()
        {
            EMA_Fast = Indicators.ExponentialMovingAverage(MarketSeries.Close, 50);
            EMA_Slow = Indicators.ExponentialMovingAverage(MarketSeries.Close, 100);
            Stochastics = Indicators.StochasticOscillator(9, 3, 9, MovingAverageType.Exponential);
            RSI = Indicators.RelativeStrengthIndex(MarketSeries.Close, 14);
        }

        protected override void OnTick()
        {
            if ((Server.Time.Hour > 17) && (Server.Time.Hour < 22))
                return;

            if ((NoOrders()) && (RSI.Result.IsRising()) && (EMA_Fast.Result.LastValue > EMA_Slow.Result.LastValue) && (EMA_Fast.Result.IsRising()) && (Stochastics.PercentK.IsRising()) && (Stochastics.PercentK.LastValue < 20) && (Stochastics.PercentK.LastValue > Stochastics.PercentD.LastValue))
            {
                ExecuteMarketOrder(TradeType.Buy, Symbol, 100000, "Stochastics Scalping", 10, 12);
            }

            if ((Stochastics.PercentK.LastValue > 80))
            {
                foreach (Position pos in Positions)
                {
                    if (pos.SymbolCode == Symbol.Code)
                        ClosePosition(pos);
                }
            }
        }

        protected override void OnStop()
        {
            // Put your deinitialization logic here
        }

        bool NoOrders()
        {
            foreach (Position pos in Positions)
            {
                if (pos.SymbolCode == Symbol.Code)
                    return false;
            }

            foreach (PendingOrder po in PendingOrders)
            {
                if (po.SymbolCode == Symbol.Code)
                    return false;
            }

            return true;
        }
    }
}

 

Drummond360 said:

If you liked those results check out this little weapon!

 

 


@sifneos4fx

markae
31 Jan 2018, 22:57 ( Updated at: 21 Dec 2023, 09:20 )

RE:

Drummond360 said:

If you liked those results check out this little weapon!

 

Do you believe it can work on a live account? Would it be possible to make a backtest with fixed lotsize? And is it right that you have backtested only 1-2 days?


@markae

markae
01 Feb 2018, 09:06 ( Updated at: 21 Dec 2023, 09:20 )

Okay, I think I got it :-D


@markae

Drummond360
01 Feb 2018, 11:33 ( Updated at: 21 Dec 2023, 09:20 )

RE:

Looks like you got it! Well played sir!....

To answer your questions;  I've found plenty of backtesting dates where this works but due to the high volume of trades I can only get a complete backtest on a very small date range... 

In theory, if you have an STP broker there's no reason why this can't work on a live account. I'll be checking for these conditions onTick with every robot I make from now on, even if it never places a trade at least I know the potential is there...

 

markae said:

Okay, I think I got it :-D

 


@Drummond360

markae
01 Feb 2018, 12:18 ( Updated at: 21 Dec 2023, 09:20 )

RE: RE:

You said it already correct:

Drummond360 said:

In theory, if...

I'm sorry to say, that those backtests never represents how your cBot would work in a real live environment. There are a lot of other factors which need to be considered, for example slippage, execution delay, variable spreads and so on.

I have some robots which really works, but the backtests are looking by far not so fantastic. Here is an example of one of my bots for EURUSD (01/01/2016-31/01/2018, Commission of $3 per round turn lot)

And here my first forward test on demo with 3 of my cBots running on the same account (since monday I have it running on a live account too):


@markae

Drummond360
01 Feb 2018, 17:55 ( Updated at: 21 Dec 2023, 09:20 )

RE: RE: RE:

 

Nice stats! Might you be interested in collaborating? Drop me an email if you'd like to discuss? ian@3sixty.me.uk

 

 

markae said:

You said it already correct:

Drummond360 said:

In theory, if...

I'm sorry to say, that those backtests never represents how your cBot would work in a real live environment. There are a lot of other factors which need to be considered, for example slippage, execution delay, variable spreads and so on.

I have some robots which really works, but the backtests are looking by far not so fantastic. Here is an example of one of my bots for EURUSD (01/01/2016-31/01/2018, Commission of $3 per round turn lot)

And here my first forward test on demo with 3 of my cBots running on the same account (since monday I have it running on a live account too):

 


@Drummond360

markae
02 Feb 2018, 15:10

RE: RE: RE: RE:

Drummond360 said:

 

Nice stats! Might you be interested in collaborating? Drop me an email if you'd like to discuss? ian@3sixty.me.uk

 

Ok, I'll get in contact with you the next days.

 

Regarding my cBots: maybe I will sell a limited number of licenses of my bots to get a good starting capital for trading, but thats still not decided. As far as I know Spotware is planing a market to sell his own products like cBots.


@markae

zedodia
03 Jun 2018, 02:10 ( Updated at: 21 Dec 2023, 09:20 )

RE: RE:

patrick.sifneos@gmail.com said:

This is a prototype of scalping Bot.

Rules:

  • Timeframe: 1 Minute. May also work on 5 minutes 
  • Stochastic K% < 20 and Stochastics K% > Stochastics D%
  • Stochsastic K% should rising
  • RSI should rising
  • Close on Stochsatics K% > 80

Play with parameters ans let me know what you think.

 

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo
{
    [Robot(TimeZone = TimeZones.CentralEuropeanStandardTime, AccessRights = AccessRights.None)]


    public class NewcBot : Robot
    {
        private MovingAverage EMA_Fast;
        private MovingAverage EMA_Slow;
        private StochasticOscillator Stochastics;
        private RelativeStrengthIndex RSI;

        protected override void OnStart()
        {
            EMA_Fast = Indicators.ExponentialMovingAverage(MarketSeries.Close, 50);
            EMA_Slow = Indicators.ExponentialMovingAverage(MarketSeries.Close, 100);
            Stochastics = Indicators.StochasticOscillator(9, 3, 9, MovingAverageType.Exponential);
            RSI = Indicators.RelativeStrengthIndex(MarketSeries.Close, 14);
        }

        protected override void OnTick()
        {
            if ((Server.Time.Hour > 17) && (Server.Time.Hour < 22))
                return;

            if ((NoOrders()) && (RSI.Result.IsRising()) && (EMA_Fast.Result.LastValue > EMA_Slow.Result.LastValue) && (EMA_Fast.Result.IsRising()) && (Stochastics.PercentK.IsRising()) && (Stochastics.PercentK.LastValue < 20) && (Stochastics.PercentK.LastValue > Stochastics.PercentD.LastValue))
            {
                ExecuteMarketOrder(TradeType.Buy, Symbol, 100000, "Stochastics Scalping", 10, 12);
            }

            if ((Stochastics.PercentK.LastValue > 80))
            {
                foreach (Position pos in Positions)
                {
                    if (pos.SymbolCode == Symbol.Code)
                        ClosePosition(pos);
                }
            }
        }

        protected override void OnStop()
        {
            // Put your deinitialization logic here
        }

        bool NoOrders()
        {
            foreach (Position pos in Positions)
            {
                if (pos.SymbolCode == Symbol.Code)
                    return false;
            }

            foreach (PendingOrder po in PendingOrders)
            {
                if (po.SymbolCode == Symbol.Code)
                    return false;
            }

            return true;
        }
    }
}

 

Drummond360 said:

If you liked those results check out this little weapon!

 

 

Is this for real? I copied that code posted and had a play with parameters but i cant get it to trade very often at all. let alone to great profit. Any chance you can share a range at all?


@zedodia

deanmikan@gmail.com
04 Jun 2018, 03:45 ( Updated at: 21 Dec 2023, 09:20 )

RE: RE: RE:

zedodia said:

patrick.sifneos@gmail.com said:

This is a prototype of scalping Bot.

Rules:

  • Timeframe: 1 Minute. May also work on 5 minutes 
  • Stochastic K% < 20 and Stochastics K% > Stochastics D%
  • Stochsastic K% should rising
  • RSI should rising
  • Close on Stochsatics K% > 80

Play with parameters ans let me know what you think.

 

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo
{
    [Robot(TimeZone = TimeZones.CentralEuropeanStandardTime, AccessRights = AccessRights.None)]


    public class NewcBot : Robot
    {
        private MovingAverage EMA_Fast;
        private MovingAverage EMA_Slow;
        private StochasticOscillator Stochastics;
        private RelativeStrengthIndex RSI;

        protected override void OnStart()
        {
            EMA_Fast = Indicators.ExponentialMovingAverage(MarketSeries.Close, 50);
            EMA_Slow = Indicators.ExponentialMovingAverage(MarketSeries.Close, 100);
            Stochastics = Indicators.StochasticOscillator(9, 3, 9, MovingAverageType.Exponential);
            RSI = Indicators.RelativeStrengthIndex(MarketSeries.Close, 14);
        }

        protected override void OnTick()
        {
            if ((Server.Time.Hour > 17) && (Server.Time.Hour < 22))
                return;

            if ((NoOrders()) && (RSI.Result.IsRising()) && (EMA_Fast.Result.LastValue > EMA_Slow.Result.LastValue) && (EMA_Fast.Result.IsRising()) && (Stochastics.PercentK.IsRising()) && (Stochastics.PercentK.LastValue < 20) && (Stochastics.PercentK.LastValue > Stochastics.PercentD.LastValue))
            {
                ExecuteMarketOrder(TradeType.Buy, Symbol, 100000, "Stochastics Scalping", 10, 12);
            }

            if ((Stochastics.PercentK.LastValue > 80))
            {
                foreach (Position pos in Positions)
                {
                    if (pos.SymbolCode == Symbol.Code)
                        ClosePosition(pos);
                }
            }
        }

        protected override void OnStop()
        {
            // Put your deinitialization logic here
        }

        bool NoOrders()
        {
            foreach (Position pos in Positions)
            {
                if (pos.SymbolCode == Symbol.Code)
                    return false;
            }

            foreach (PendingOrder po in PendingOrders)
            {
                if (po.SymbolCode == Symbol.Code)
                    return false;
            }

            return true;
        }
    }
}

 

Drummond360 said:

If you liked those results check out this little weapon!

 

 

Is this for real? I copied that code posted and had a play with parameters but i cant get it to trade very often at all. let alone to great profit. Any chance you can share a range at all?

Of course this is not real... Think logically.


@deanmikan@gmail.com

zedodia
29 Jun 2018, 14:09

RE: RE: RE: RE:

Im still new to bots, ive been trading for a while now but bot facinate me for many reasons. im trying to find an actual bot that will be profitable. is this a dream or is it actually something i can obtain and help escape the rat race?


@zedodia

mparama
01 Jul 2018, 18:35

RE: RE: RE: RE: RE:

zedodia said:

Im still new to bots, ive been trading for a while now but bot facinate me for many reasons. im trying to find an actual bot that will be profitable. is this a dream or is it actually something i can obtain and help escape the rat race?

There is no a single bot that is always profitable.

To be profitable you need to build a strategy with min 5 to 10 and more bots with different logics.


@mparama

sifneos4fx
01 Jul 2018, 18:41

RE: RE: RE: RE: RE:

If manual trading can work, then algo-trading works 1000% better. There is no better way to trade than algo-trading. I am profitable over 1.5 years, just with one single bot running on 28 major forex pairs. However, you will never find a bot to buy, if someone sells it, do not buy, it will not work. Build your own bot!!!

Good Luck!!!

 

zedodia said:

Im still new to bots, ive been trading for a while now but bot facinate me for many reasons. im trying to find an actual bot that will be profitable. is this a dream or is it actually something i can obtain and help escape the rat race?

 


@sifneos4fx

zedodia
08 Jul 2018, 12:24

RE: x6

Im finding that building a bot is very difficult. the language is just not taking to my brain atm. is there a good way to learn the coding? ive been trying to learn from the bots on this site and work backwards.

 

 

 

 

patrick.sifneos@gmail.com said:

If manual trading can work, then algo-trading works 1000% better. There is no better way to trade than algo-trading. I am profitable over 1.5 years, just with one single bot running on 28 major forex pairs. However, you will never find a bot to buy, if someone sells it, do not buy, it will not work. Build your own bot!!!

Good Luck!!!

 

zedodia said:

Im still new to bots, ive been trading for a while now but bot facinate me for many reasons. im trying to find an actual bot that will be profitable. is this a dream or is it actually something i can obtain and help escape the rat race?

 

 


@zedodia

ClickAlgo
08 Jul 2018, 14:22

If you want to learn how to create your own automated trading strategies then the link below will help you get started.

https://clickalgo.com/cTrader-algorithmic-trading-school-for-beginners

Paul Hayes
cTrader Education
Emailcontact@clickalgo.com
Phone: (44) 203 289 6573
Websitehttps://clickalgo.com


@ClickAlgo

SuccinctAlgoTrading
30 Jan 2019, 22:50

RE: RE: RE: RE:

deanmikan@gmail.com said:

Of course this is not real... Think logically.

 

Hi All, 

Yes this bot is real and it is backtested on real tick data (EURUSD)..... We've made a short youtube tutorial on the bot, take a look and run the test yourself: https://youtu.be/5ZvPQ2r1Ls4

All the best,

www.succinctalgo.co.uk

Here's the code:

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Internals;

namespace cAlgo
{
    [Robot(TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
    public class NegativeSpreadBot : Robot
    {

        string label = "Negative Spread Bot";

        protected override void OnTick()
        {

            var positionSearch = Positions.FindAll(label, Symbol);

            var spread = Symbol.Spread / Symbol.PipSize;

            if (spread < -2)
            {
                ExecuteMarketOrder(TradeType.Sell, Symbol, 100000, label);
                ExecuteMarketOrder(TradeType.Buy, Symbol, 100000, label);

                foreach (Position position in positionSearch)
                {
                    ClosePosition(position);
                }
            }
        }
    }
}

 


@SuccinctAlgoTrading

firemyst
15 May 2023, 13:15

RE: RE:

sifneos4fx said:

This is a prototype of scalping Bot.

Rules:

  • Timeframe: 1 Minute. May also work on 5 minutes 
  • Stochastic K% < 20 and Stochastics K% > Stochastics D%
  • Stochsastic K% should rising
  • RSI should rising
  • Close on Stochsatics K% > 80

Play with parameters ans let me know what you think.

 

using System;
using System.Linq;
using cAlgo.API;
using cAlgo.API.Indicators;
using cAlgo.API.Internals;
using cAlgo.Indicators;

namespace cAlgo
{
    [Robot(TimeZone = TimeZones.CentralEuropeanStandardTime, AccessRights = AccessRights.None)]


    public class NewcBot : Robot
    {
        private MovingAverage EMA_Fast;
        private MovingAverage EMA_Slow;
        private StochasticOscillator Stochastics;
        private RelativeStrengthIndex RSI;

        protected override void OnStart()
        {
            EMA_Fast = Indicators.ExponentialMovingAverage(MarketSeries.Close, 50);
            EMA_Slow = Indicators.ExponentialMovingAverage(MarketSeries.Close, 100);
            Stochastics = Indicators.StochasticOscillator(9, 3, 9, MovingAverageType.Exponential);
            RSI = Indicators.RelativeStrengthIndex(MarketSeries.Close, 14);
        }

        protected override void OnTick()
        {
            if ((Server.Time.Hour > 17) && (Server.Time.Hour < 22))
                return;

            if ((NoOrders()) && (RSI.Result.IsRising()) && (EMA_Fast.Result.LastValue > EMA_Slow.Result.LastValue) && (EMA_Fast.Result.IsRising()) && (Stochastics.PercentK.IsRising()) && (Stochastics.PercentK.LastValue < 20) && (Stochastics.PercentK.LastValue > Stochastics.PercentD.LastValue))
            {
                ExecuteMarketOrder(TradeType.Buy, Symbol, 100000, "Stochastics Scalping", 10, 12);
            }

            if ((Stochastics.PercentK.LastValue > 80))
            {
                foreach (Position pos in Positions)
                {
                    if (pos.SymbolCode == Symbol.Code)
                        ClosePosition(pos);
                }
            }
        }

        protected override void OnStop()
        {
            // Put your deinitialization logic here
        }

        bool NoOrders()
        {
            foreach (Position pos in Positions)
            {
                if (pos.SymbolCode == Symbol.Code)
                    return false;
            }

            foreach (PendingOrder po in PendingOrders)
            {
                if (po.SymbolCode == Symbol.Code)
                    return false;
            }

            return true;
        }
    }
}

 

Just for kicks, I've been running on one of my VPS's against a demo account across 26 forex pairs M1 timeframe. So far one 0.7pip winner and 6 losses.

 


@firemyst