Regular visitors will have noticed ever increasing amounts of spam on the Trading Gurus Community Forum. On November 24th 2012 we implemented some changes:

1. New users will be moderated 2. Registered users who have a post count of zero will not be able to view attachments or download code. 3. Registered users who have a post count of zero will not be able to create a new thread

As an additional countermeasure we anticipate introducing a modest paywall in the near future.

If this is your first visit here our apologies for the inconvenience.

Existing users may wish to contribute their ideas to this thread.

Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 40

Thread: Ray Robot 2 Makes Money Trading Breakouts with MetaTrader 4

  1. #21
    Junior Member
    Join Date
    Dec 2011
    Posts
    3

  2. #22
    Administrator Jim's Avatar
    Join Date
    Apr 2010
    Location
    South West England
    Posts
    489
    Hi Bigpipn,

    Quote Originally Posted by bigpipn View Post
    A more fair analysis would be to use a 3rd party reliable feed/broker (I suggest integral liquidity) to signal in the trades simultaneously, as these accounts are run on their "market maker"/"instant execution" accounts. This means that they are giving you the best (or worst lol) quote they have to offer from their pricing machine.
    Sounds like you're referring to Ray's spread betting comparison test? If so, then one of the points of this exercise is to experiment with pending orders rather than market entries. Particularly in such circumstances, why do think "signal[ing] in the trades simultaneously" from a 3rd party feed is "fairer" than running exactly the same "robot" at two or more different brokers?

    I have also attached a 3rd Party MT4 platform. The automatic feed/broker in the demo is Swiss Quote. Notice how wide the spreads get during certain times of the day and how accurate/fortuitous the intra-day gaps are. This is raw data from a LP. Spreads are wider but are good for testing because you will under-promise on your back tests but over-deliver on your live accounts. I'm not affiliated with Rous at all, they were very helpful with the extensive list of questions I had.

    I have no doubt that your profit margin will increase if you go ahead and use this 3rd party MT4 platform instead of the one you download from your broker. Do NOT update when prompted.
    A perennial question when trading spot FX. In the absence of a centralised exchange, whose quotes should you trust?

    Added your system to test and will report back with results.
    Please bear in mind that Ray's default settings are not optimised for any particular instrument. If you discover some settings that work well in forward tests please do report back!

    Cheers,

    Jim
    Reality is merely an illusion, albeit a very persistent one - Albert Einstein

  3. #23
    Junior Member
    Join Date
    Mar 2012
    Posts
    1
    Hello, which program will open the file RayRobot2.mq4 ???

  4. #24
    Administrator Jim's Avatar
    Join Date
    Apr 2010
    Location
    South West England
    Posts
    489
    Hi lawserge,

    Quote Originally Posted by lawserge View Post
    Hello, which program will open the file RayRobot2.mq4 ???
    The MetaTrader 4 editor (MetaEditor for short) is the option chosen by most people. It is freely downloadable from the websites of numerous brokers around the world, and also from MetaTrader4.com. Note that doing so is recommended for educational purposes only!

    Alternatively the contents of any .MQ4 file can be inspected using the text editor of your choice, such as Notepad for example.

    Cheers,

    Jim
    Reality is merely an illusion, albeit a very persistent one - Albert Einstein

  5. #25
    Hi Jim,

    i have downloaded the EA and have made some backtesting starting at 2005 on gbpusd. The EA has made 1250 trades and gained approximately 1700 pips with 50 pips stop and 70 pips target. Good results for such a simple strategy without any filter or trend recognition. I have added a little filter. We usually don't want to take long trades in strong downtrending markets und no short trades in strong uptrending markets. I like the commodity channel index indicator because it tells the deviation from a moving average with an absolute number. I know that every moving average is lagging, but in my opinion a lagging filter is better than no filter in an EA. From the backtesting of my strategies i found that the period of 50 makes valuable indication in different timeframes (1day, 4hour and 1hour) if we are in an uptrend or a downtrend. I added this filter to your strategy too. The EA now generates 950 trades makes 2600 pips with 50 pips stop and 70 pips targets. It seems that there are filtered a lot of bad trades. I didn't checked the entire code of your EA and hope that i don't have produced orphaned positions that are never closed and therefore sophiticate the backtesting results. Here are my changes in the CheckEntry() method to accept long trades only of the cci is above -60 and short trades if the cci is below +60:

    Code:
    double cci = iCCI(Symbol(),NULL, 50, PRICE_TYPICAL,0);
             
             if(cci > -60.0) {
                Orders[LONG_UNIT][ORDER_NO] = PendingOrder(Symbol(), LongType, LongEntry, PositionSize(),
                         LongEntry + Points * Target, LongEntry - Points * Stop);
                if (Orders[LONG_UNIT][ORDER_NO] > 0) {
                   Print("Long entry ", LongEntry, " placed at ", TimeToStr(TimeCurrent()));
                   Orders[LONG_UNIT][ORDER_STATUS] = ORDER_PENDING;
                }
             }
    
    cci = iCCI(Symbol(),NULL, 50, PRICE_TYPICAL,0);
             
             if(cci < 60.0) {
             
                Orders[SHORT_UNIT][ORDER_NO] = PendingOrder(Symbol(), ShortType, ShortEntry, PositionSize(),
                         ShortEntry - Points * Target, ShortEntry + Points * Stop);
                if (Orders[SHORT_UNIT][ORDER_NO] > 0) {
                   Print("Short entry ", ShortEntry, " placed at ", TimeToStr(TimeCurrent()));
                   Orders[SHORT_UNIT][ORDER_STATUS] = ORDER_PENDING;
                }
             
             }
    Are you trading live with your EA? If so, on which pairs and which settings?

  6. #26
    Administrator Jim's Avatar
    Join Date
    Apr 2010
    Location
    South West England
    Posts
    489
    Hi forexpattern,

    Quote Originally Posted by forexpattern View Post
    I have added a little filter. We usually don't want to take long trades in strong downtrending markets und no short trades in strong uptrending markets. Here are my changes in the CheckEntry() method to accept long trades only of the cci is above -60 and short trades if the cci is below +60
    Thanks for the suggestion! Ray is indeed stupidly simple, and I'm sure he would benefit from some additional simple filters. We'll create RR2-CCI to give your idea a try, and let you know what we come up with in the way of test results. What timeframe were you using for your own tests?

    Are you trading live with your EA? If so, on which pairs and which settings?
    Ray is trading live (and profitably!) on GBP/USD with a number of different brokers. For more information take a look at the live SB comparison test.

    Cheers,

    Jim

    P.S. A new hybrid of RR2 incorporating your suggestion is now available in a thread of his very own. Please wander over there and lets us know if the new Ray behaves the way you would expect.
    Last edited by Jim; 04-29-2012 at 06:20 PM. Reason: Added link to RR2-CCI
    Reality is merely an illusion, albeit a very persistent one - Albert Einstein

  7. #27
    Administrator Jim's Avatar
    Join Date
    Apr 2010
    Location
    South West England
    Posts
    489

    A new version of Ray Robot II

    A new version of Ray Robot II, especially for Laurence and Mintaka.

    Apart from a number of cosmetic improvements, a significant change is the introduction of an "expiry time" for pending orders. This can be used to prevent the MetaTrader 4 strategy tester booking a hefty profit on a gap opening after the weekend, or overnight for indices. Unfortunately now the backtest results don't look anything like as spectacular

    Here's some optimisation results for the DAX on hourly bars:

    2012-04-29_RR2_DAX_Opt.png

    No longer a sea of bright green I'm afraid. Here's a backtest using the best settings above:

    2012-04-29_RR2_DAX_Best.png

    An "optimal" profit factor of 1.39 is once again nothing to write home about. However by way of consolation take a good look at Ray's live spread betting test, where despite keeping it stupidly simple, Ray has had five winning months in a row trading daily bars of GBP/USD!
    Attached Files Attached Files
    Reality is merely an illusion, albeit a very persistent one - Albert Einstein

  8. #28
    Junior Member
    Join Date
    Jun 2012
    Posts
    1
    Quote Originally Posted by Jim View Post
    Following some festive Halloween fun over on the AlgoTrader development group a new "robot" was conceived. After a remarkably brief gestation period the MetaTrader version of the son of Ray the Random Robot has now been born!

    Ray Robot II has learned something from his father's experiences, and uses slightly more intelligent entries. RR2 waits for the end of a bar, then places a pair of pending orders at or just beyond the high and low of that bar. These "bracket orders" can either be stops, in which case the son of Ray hopes for a breakout, or they can be limit orders, in which case he is hoping for some "mean reversion" to take place.

    Ray Robot the second has also now seen his father's equity curve, and decided to ditch Martingale money management in favour of the far more sensible methods used by our "London Breakout Robot". He still uses his father's original exit method though, which consists of a fixed profit target and stop loss.

    Here's the source code for our latest creation, together with RR2's very first backtest results:

    Attachment 256

    This is what a few month's worth of breakout trades from daily bars of EUR/USD on an Alpari UK demo account looks like:

    Attachment 255

    Not bad pocket money for such a young whippersnapper?

    P.S. Here's the latest version:

    Hi jim i m newbie in forex trading and tried ray robot 2 in demo account from alpari it's working very well and strategy is good but the problem i m having is robot not taking buy orders only sell therefore i m loosing buying opportunities. If you could help me to find out the problem would be much appreciated. Kind Regards, atrader

  9. #29
    Administrator Jim's Avatar
    Join Date
    Apr 2010
    Location
    South West England
    Posts
    489
    Hi A,

    Are you using Ray's default input settings on GBP/USD by any chance? One reason I ask is that Ray's live trading at Alpari hasn't been going quite so well recently, and April and May proved to be losing months for him. Please note that last time I looked the standard Alpari UK demo account (as opposed to spreadbet) actually seemed to be based on their "Pro" spreads rather than on what Alpari offer us mere mortals, which would certainly help his bottom line.

    Be that as it may, please see if you can dig out one of Ray's log files from the MT4 experts/log folder. If you can zip up one from a day when you experienced the problem and upload it here we'll take a look.

    Cheers,

    Jim
    Reality is merely an illusion, albeit a very persistent one - Albert Einstein

  10. #30
    Junior Member
    Join Date
    Aug 2012
    Posts
    5
    Newbie here. Just testing out RR II on EURUSD (1 minute) on Demo account. I tried some parameters but the bot seem to be losing money consistently I must be doing something wrong.. I am using Demo acct from UWC. maybe their spreads is too high?

Page 3 of 4 FirstFirst 1234 LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •