Mr4x
Mr4x's avatar

Info

Username:Mr4x
Name:Mr4x
Member since: 12 Apr 2019

About

None

Signature

None

Last Algorithm Comments

@Smart Grid V3:  25 Apr 2020, 06:22


CoreTradingHouse, A couple more observations too: First Volume is always 1000, regardless of what number you put in the field. Volume Exponent isn't accurate, and sometimes places the highest volume trade on starting a new grid even once the grid restarted. Eg: previous grid may get to 12 lots, then grid closes, then new grid starts at 12 lots instead of 0.1. Just some hopefully helpful observations so far :) Mr4x

@Smart Grid V3:  24 Apr 2020, 10:00


CoreTradingHouse, I compiled your version of the grid trade and definitely very interesting results. 20% profit over a 3 year period on EURUSD but one thing I noticed is that it only places sell trades? Anyway thought you should know :) Another idea I have, but my bot-building skills are basic at best, is to incorporate a moving average to smartgrid V3 that can be defined by the user, and have the bot only grid in the direction of the moving average, with an overall take profit that closes all long and short positions when x amount in profit. What do you think? Mr4x

@RSI Range Robot:  14 Apr 2020, 11:37


Basic adjustment to code to make all parameters configurable, including upper and lower RSI range and stop-loss / take-profit. // ------------------------------------------------------------------------------------------------- // //    This code is a cTrader Automate API example. // //    This cBot is intended to be used as a sample and does not guarantee any particular outcome or //    profit of any kind. Use it at your own risk. //     //    All changes to this file might be lost on the next application update. //    If you are going to modify this file please make a copy using the "Duplicate" command. // //    The "Sample RSI cBot" will create a buy order when the Relative Strength Index indicator crosses the  level 30,  //    and a Sell order when the RSI indicator crosses the level 70. The order is closed be either a Stop Loss, defined in  //    the "Stop Loss" parameter, or by the opposite RSI crossing signal (buy orders close when RSI crosses the 70 level  //    and sell orders are closed when RSI crosses the 30 level).  // //    The cBot can generate only one Buy or Sell order at any given time. // // ------------------------------------------------------------------------------------------------- using System; using System.Linq; using cAlgo.API; using cAlgo.API.Indicators; using cAlgo.API.Internals; using cAlgo.Indicators; namespace cAlgo {     [Robot(TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]     public class SampleRSIcBot : Robot     {         [Parameter("Quantity (Lots)", Group = "Volume", DefaultValue = 1, MinValue = 0.01, Step = 0.01)]         public double Quantity { get; set; }         [Parameter("Source", Group = "RSI")]         public DataSeries Source { get; set; }         [Parameter("Periods", Group = "RSI", DefaultValue = 14)]         public int Periods { get; set; }         [Parameter("Lower RSI Level", Group = "RSI", DefaultValue = 30, MinValue = 0, MaxValue = 50)]         public int LRL { get; set; }         [Parameter("Upper RSI Level", Group = "RSI", DefaultValue = 70, MinValue = 50, MaxValue = 100)]         public int URL { get; set; }         [Parameter("Take Profit in pips", Group = "TP SL", DefaultValue = 100)]         public int TP { get; set; }         [Parameter("Stop Loss in pips", Group = "TP SL", DefaultValue = 100)]         public int SL { get; set; }         private RelativeStrengthIndex rsi;         protected override void OnStart()         {             rsi = Indicators.RelativeStrengthIndex(Source, Periods);         }         protected override void OnTick()         {             if (rsi.Result.LastValue < LRL)             {                 Close(TradeType.Sell);                 Open(TradeType.Buy);             }             else if (rsi.Result.LastValue > URL)             {                 Close(TradeType.Buy);                 Open(TradeType.Sell);             }         }         private void Close(TradeType tradeType)         {             foreach (var position in Positions.FindAll("SampleRSI", SymbolName, tradeType))                 ClosePosition(position);         }         private void Open(TradeType tradeType)         {             var position = Positions.Find("SampleRSI", SymbolName, tradeType);             var volumeInUnits = Symbol.QuantityToVolumeInUnits(Quantity);             if (position == null)                 ExecuteMarketOrder(tradeType, SymbolName, volumeInUnits, "SampleRSI", SL, TP);         }     } }

@Smart Grid:  23 May 2019, 14:44


Friends, I feel like I have almost honed in on something worthy. I have figured that USDJPY and CHFJPY are very highly correlated most of the time, so therefor being long USDJPY and short CHFJPY at the same time can quite often yield good results, the swap is also positive overall this way. The method I am using so far, with positive returns on both days after 2 days, cannot be backtested as it relies on running 2 instances of this bot on the same account at the same time (which also keeps your equity somewhat in balance). This means it has to be used in a demo account, unless one of you smart cookies can figure out a way to cross-test and share the best results. Here are my settings so far, please try to optimise them for better return / lower drawdown and get back to me: Chart : USDJPY Timeframe : 15 min Buy : Yes Sell : No Pipstep : 5 Volume Exponent : 1.1 Average TP : 4 First Volume : 2000 (0.20 LOT) Max Spread : 2 Account Margin : 40000 US DOLLAR Leverage : 1/500   ---AND---   Chart : CHFJPY Timeframe : 15 min Buy : No Sell : Yes Pipstep : 5 Volume Exponent : 1.1 Average TP : 4 First Volume : 2000 (0.20 LOT) Max Spread : 2 Account Margin : 40000 US DOLLAR Leverage : 1/500

Last Forum Posts

@DowRider - NewStrategy - Exclusively DOW (DJIA/US30):  25 Nov 2021, 10:36


Great performance so far mate... I notice your strategy involves some sort of mean reversion... Do you keep an eye on the news and avoid trading during days like when we had the meltdown in February / March 2020?

Also, if you wanted to consider a strategy that doesn't need so much capital invested, you could try applying this to the US500 since its correlation with US30 is almost 100% most of the time and you can trade much smaller lot sizes :)

@Conservative Investment - ~100% p.a w/ 3 years live data:  21 Oct 2021, 14:25


Hi Everybody,

I closed down my strategy back in April due to personal circumstances which meant I could not be at a computer to monitor the trades.

I have now restarted the strategy and tweaked it a little, using the same account as I was using earlier in the year to prove I did not blow up the account.

New link to my strategy is below :)

https://ct.icmarkets.com/copy/strategy/37479

Sorry I do not have a telegram group

@Conservative Investment - ~100% p.a w/ 3 years live data:  21 Oct 2021, 14:24


Hi Everybody,

I closed down my strategy back in April due to personal circumstances which meant I could not be at a computer to monitor the trades.

I have now restarted the strategy and tweaked it a little, using the same account as I was using earlier in the year to prove I did not blow up the account.

New link to my strategy is below :)

https://ct.icmarkets.com/copy/strategy/37479

@Simple cBot from custom indicator:  28 Mar 2021, 11:14


Hi,

I have an indicator (code posted below) which displays the output of the correlation between two symbols. How would I incorporate a simple ExecuteMarketOrder to a cBot say when correlation drops below 50? Are there any special steps to reference a custom indicator compared to referencing a standard one (such as moving average)?

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

// (C) 2014 marekfx

namespace cAlgo
{
    [Indicator(IsOverlay = false, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None, AutoRescale = true)]
    public class Correlation : Indicator
    {
        private MarketSeries _symbol2Series;

        [Parameter(DefaultValue = "USDCHF")]
        public string Symbol2 { get; set; }

        [Parameter(DefaultValue = 50)]
        public int Lookback { get; set; }

        [Output("Correlation", PlotType = PlotType.DiscontinuousLine)]
        public IndicatorDataSeries Result { get; set; }

        protected override void Initialize()
        {
            _symbol2Series = MarketData.GetSeries(Symbol2, TimeFrame);
        }

        public override void Calculate(int index)
        {
            DateTime date = MarketSeries.OpenTime[index];

            //get index for Symbol 2 series
            var idx2 = _symbol2Series.OpenTime.GetIndexByExactTime(date);

            if (index < Lookback || idx2 < Lookback)
                return;

            double[] tab1 = new double[Lookback];
            double[] tab2 = new double[Lookback];

            //populate tab1 and tab2 arrays with close for Symbol 1 (MarketSeries) and Symbol 2
            for (int i = 0; i < Lookback; i++)
            {
                tab1[i] = MarketSeries.Close[index - Lookback + i];
                tab2[i] = _symbol2Series.Close[idx2 - Lookback + i];
            }

            Result[index] = Stat.Correlation(tab1, tab2);
        }
    }

    //Correlation from (c) http://mantascode.com/c-how-to-get-correlation-coefficient-of-two-arrays/
    public class Stat
    {
        public static double Correlation(double[] array1, double[] array2)
        {
            double[] array_xy = new double[array1.Length];
            double[] array_xp2 = new double[array1.Length];
            double[] array_yp2 = new double[array1.Length];
            for (int i = 0; i < array1.Length; i++)
                array_xy[i] = array1[i] * array2[i];
            for (int i = 0; i < array1.Length; i++)
                array_xp2[i] = Math.Pow(array1[i], 2.0);
            for (int i = 0; i < array1.Length; i++)
                array_yp2[i] = Math.Pow(array2[i], 2.0);
            double sum_x = 0;
            double sum_y = 0;
            foreach (double n in array1)
                sum_x += n;
            foreach (double n in array2)
                sum_y += n;
            double sum_xy = 0;
            foreach (double n in array_xy)
                sum_xy += n;
            double sum_xpow2 = 0;
            foreach (double n in array_xp2)
                sum_xpow2 += n;
            double sum_ypow2 = 0;
            foreach (double n in array_yp2)
                sum_ypow2 += n;
            double Ex2 = Math.Pow(sum_x, 2.0);
            double Ey2 = Math.Pow(sum_y, 2.0);

            return (array1.Length * sum_xy - sum_x * sum_y) / Math.Sqrt((array1.Length * sum_xpow2 - Ex2) * (array1.Length * sum_ypow2 - Ey2));
        }
    }
}

@Conservative Investment - ~100% p.a w/ 3 years live data:  10 Feb 2021, 13:20


TheMC said:

Hi, I would like to copy you.
What does it mean that it is set at 200%? Double the size compared to what was done on myfxbook (so double the roi and any dd?). Where do you recommend putting the SL? 10% is enough?

Hi mate thanks for asking,

The performance should be roughly double as well as the DD yes. Although trades can vary because they are started and stopped at the same time as the master MT4 account, but quote prices may be slightly different between the platforms so you may end up with a bit more or a bit less each trade, also ctrader commissions are higher than MT4...

The max DD of the MT4 strategy so far is 12% so with mine it could potentially reach 24%, so I would really advise against setting SL anything less than that.

For reference, Relax and Fibo23 often have DD's well above 40% and they are still going.

@The best coppy strategy:  05 Feb 2021, 03:23


long.phamdinhhoang said:

Mr4x said:

You could try my strategy, low drawdown and 100% p.a with 3 year live backtested.

https://ct.icmarkets.com/copy/strategy/14462

The other popular ones would be Relax and Fibo23 - both are tracking at about 20% per month but both follow almost identical strategies using EURUSD whereas mine uses GBPCAD, so you could put a little in each for diversification of assets in case one or the other goes bust one day :)

Hi Mr4x,

I think you put the wrong link (it's relax1 strategy i think). 

Like you, I also developed a strategy (using a bot) that focus on minimizing equity/balance drawdown while still generates a steady return (15%-25%) (2 years backtested and 5 months forwardtested)

In fact, my strategy is a lot like Relax strategy, the only thing that is different is I trade smaller lots and take profit earlier.

If you can't copy Relax then I hope you spend some time to look at my strategy. You can check out my strategy at: https://ct.icmarkets.com/copy/strategy/21154

Have a great day everyone and happy trading.

Kind regards,

Long Pham

Hi Long Pham,

Thank you so much for spotting that! Haha I must have copied the wrong link whilst looking at his strat. I have edited my post now.

@The best coppy strategy:  04 Feb 2021, 13:41


You could try my strategy, low drawdown and 100% p.a with 3 year live backtested.

https://ct.icmarkets.com/copy/strategy/17195

The other popular ones would be Relax and Fibo23 - both are tracking at about 20% per month but both follow almost identical strategies using EURUSD whereas mine uses GBPCAD, so you could put a little in each for diversification of assets in case one or the other goes bust one day :)

@Fibonacci Indicator built in to cTrader:  04 Feb 2021, 13:37


Hi,

cTrader has many amazing indicators built in, but I feel a basic Fib retracement indicator as part of the standard kit would help a lot of traders.

Fib lines could be fixed (61.8%, 38.2%, 50%, and 23.6%), or user defined :)

Thank you

@Conservative Investment - ~100% p.a w/ 3 years live data:  04 Feb 2021, 13:30


Hi copy traders,

Now that cMirror is no longer supported, get on to a broker like ICMarkets that supports cTrader copy!

If you are looking for a strategy to follow with 3 years of live account data as validation, then come check out my strategy.

This strat uses GBPCAD at the end of the US session, a good way to diversify your portfolio with a strat that doesn't follow EURUSD like all the popular ones.

Based on an MT4 strategy that isn't taking on new customers at the moment, with solid performance and low drawdown since Feb 2018, click here:

Link to my strategy that is set at 200% compared to the original strategy and doing very well:

https://ct.icmarkets.com/copy/strategy/37479

Demo accounts welcome, and I will be happy to create more strategies with lower risk and lower reward if there is genuine interest :)

@Conservative Investment - ~100% p.a w/ 3 years live data:  04 Feb 2021, 13:10


Hi copy traders,

If you are looking for a strategy to follow with 3 years of live account data as validation, then come check out my strategy.

This strat uses GBPCAD at the end of the US session, a good way to diversify your portfolio with a strat that doesn't follow EURUSD like all the popular ones.

Based on an MT4 strategy that isn't taking on new customers at the moment, with solid performance and low drawdown since Feb 2018, click here:

Link to my strategy that is set at 200% compared to the original strategy and doing very well:

https://ct.icmarkets.com/copy/strategy/37479

Demo accounts welcome, and I will be happy to create more strategies with lower risk and lower reward if there is genuine interest :)

Notification Publishing copyrighted material is strictly prohibited. If you believe there is copyrighted material in this section you may use the Copyright Infringement Notification form to submit a claim.

No uploaded.

Warning! Executing cBots downloaded from this section may result in loss of funds. Use them at your own risk.

No uploaded.