fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search

    Trying (and failing) to create a simple EA...appealing to all FXDreema gurus!

    Questions & Answers
    5
    40
    7806
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      SirBoyce @line last edited by

      @line Thanks!!!! That's exactly what I was looking for. Although it done run more profitably for me with the x> condition. What mods did you make (if you don't mind me asking) that produced that test report you did have up here, and what time period did you you backtest over?

      Thanks again!

      1 Reply Last reply Reply Quote 0
      • L
        line last edited by

        I removed the test report which was run on open prices which is not a good way to test, I then ran on tick and it produced 1.37pf with 200 pips ( I think) in 4-6 months on e/u. I changed the profit/loss and actually inverted the buy to a sell. I will have to run later since I am going to bed atm. I also used a marti but only at 1.5 with a limit of max lot size at .50 (starting lot size is .10, I think you had .20 at starting lot size).

        As a side note, I run at .10 since it is easier to convert to actual pips (.10 = 1 pip).

        S 1 Reply Last reply Reply Quote 0
        • S
          SirBoyce @line last edited by

          @line Thanks for that! I also inverted conditions from buy to sell (with the exception of switching the EMA component for market entry condition from 20 to 5). Trailing stop loss 15 Pips on Open with 15 Pip Step (just the same as for the Buy EA). Ran the EA on EUR/GBP and it produces some expected closes, but also some really weird ones:

          Incorrect S/L Mod and stopped out (should have been a profitable trade):

          0_1569678457272_6b037349-3ee8-4004-bdd5-c00fbc3cdcb1-image.png

          Open S/L hit no reason (should have been a break-even):

          0_1569678612944_e4d23e6a-1296-4fee-9251-0cea3d8c719b-image.png

          2 S/L stopped trades for no reason:

          0_1569678779828_4a54f5b9-0568-4f71-9d72-f34daa227f3a-image.png

          Any idea why this could be happening? Is it just inaccurate testing by MT4?

          Thanks again for all your input.

          1 Reply Last reply Reply Quote 0
          • l'andorrà
            l'andorrà last edited by

            Can you please share your last version?

            (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

            (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

            (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

            S 1 Reply Last reply Reply Quote 0
            • S
              SirBoyce @l'andorrà last edited by

              @l-andorrà https://fxdreema.com/shared/jHwBhm2Bd

              1 Reply Last reply Reply Quote 0
              • L
                line last edited by

                1_1569743579716_Tester(192) buy5.mq4 0_1569743579714_Tester(192) buy5.ex4

                1 Reply Last reply Reply Quote 0
                • L
                  line last edited by

                  Try this, I ran this on 1H tick Eur/Usd from 4/18/18 to 6/4/18 . Keep in mind I did not spend a lot of time going through all of this.

                  0_1569743851560_972bf9ca-b2c4-4a86-839d-c2c486c10390-image.png

                  S 1 Reply Last reply Reply Quote 0
                  • S
                    SirBoyce @line last edited by

                    @line Thanks, but that is not what I am looking for . On my buy conditions you have programmed to sell! I have the BUY element of my strategy done and it works profitably on certain currency pairs, 15 minute charts, during London/Euro market hours.

                    What I want now is to do with the same for short trades. I want the a SELL to execute on the following conditions:

                    • Previous candle close is a bear candle
                    • Previous candle close below EMA5
                    • Previous candle close: MACD Main is below 0.00 line
                    • Previous candle close: MACD Main is below MACD Signal line

                    Upon all the above, Sell trade open with 15 pip stop loss, trailing so that for every 15 pips price goes down during trade, stop loss moves down by 15 pips.

                    I cannot understand why the EA I shared with Andorra does not properly fulfil this strategy and stops out trades (as per screenshots).

                    S 1 Reply Last reply Reply Quote 1
                    • S
                      SirBoyce @SirBoyce last edited by

                      @sirboyce Oh great! Now when I backtested my BUY EA on GBP/USD it delivers a loss...testing on exactly the same currency pair, over the exact same period, timeframe etc. etc. etc. as I did yesterday when it delivered a really nice profit. WTF!!!!

                      How can you possibly reliably test these EA's????????

                      This project https://fxdreema.com/shared/iP90As69e (incorporating both buys and sells conditions) worked great on EUR/USD and delivered profit...right up to the last but one trade when the stop loss on the buy did not trail up again for a 15 pip win (and ended up break-even):
                      0_1569768285096_789e8a9c-fe01-4d23-b411-992db8685e9d-image.png

                      Also noticed this occasion where should have been a profitable buy but no trade:

                      0_1569768418089_d00d9167-b944-44d0-8149-c9f92163397d-image.png

                      Running exactly the same EA on GBP/USD...and the whole test f**ks up because a sell open has no stop loss at all so the test runs on thinking that the trade is open all the way to the end (and of course no further sell trade is executed):
                      0_1569768799957_16976122-6955-438d-b5b6-c96ba1f38422-image.png

                      Losing the will to live here!

                      T 1 Reply Last reply Reply Quote 0
                      • l'andorrà
                        l'andorrà last edited by

                        Honestly, I see no apparent reason for your EA not no work correctly. Maybe you couls share the whole project and then check other conditions not included in your partial one may be hundering the whole program. Otherwise, what is the quality of your tick data?

                        (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                        (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                        (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                        1 Reply Last reply Reply Quote 0
                        • T
                          trader.philipps @SirBoyce last edited by

                          @sirboyce Spread looks very high. Maybe that's the reason why some trades close late?!?

                          I like to share my knowledge, but expect the others to contribute as well.

                          S 1 Reply Last reply Reply Quote 0
                          • S
                            SirBoyce @trader.philipps last edited by

                            @trader-philipps I think that's the least of the problems with this testing 😞

                            T 1 Reply Last reply Reply Quote 0
                            • T
                              trader.philipps @SirBoyce last edited by

                              @sirboyce But it would explain different results if you choose current spread for testing

                              I like to share my knowledge, but expect the others to contribute as well.

                              S 1 Reply Last reply Reply Quote 0
                              • S
                                SirBoyce @trader.philipps last edited by

                                @trader-philipps OK, so what would you recommend changing the spread to on all tests? I am more concerned about incorrect stops, lack of any stop loss being applied upon trade open, trades not being opened on the conditions I have built into the EA etc.

                                T 1 Reply Last reply Reply Quote 0
                                • T
                                  trader.philipps @SirBoyce last edited by

                                  @sirboyce Well, for MT4 EAs I use TDS2 for testing. There you can specify variable spreads, but they keep consistent if you configure it like that. So you can run your EA on exactly same conditions several times.
                                  But I don't want to advertise here. There are probably other apps around that do a similar or better job.

                                  However, the trade without SL, was that a sell trade? If so, than you should rethink the trailing logic. If spread is 4 pips, you have to make those 4 pips first in order to kick in trailing (as you specified open price). And on the other trades, there you have 5 pips spread which is 1/3 of your trailing step target. I think it's good to test with that high spread as you can see the flaws in the logic (not by fxdreema or MT4) better.

                                  I like to share my knowledge, but expect the others to contribute as well.

                                  S 1 Reply Last reply Reply Quote 0
                                  • L
                                    line last edited by

                                    In case you have not, run on tick, set spread to something besides "current". If this does not work then you try to isolate. Probably the best to isolate is to run separate eas, one for buys and the other for sells. It does not look like there is errors but could be a bug issue.

                                    If the separation does not work, then I take apart the conditions by detach then running each condition by itself.

                                    S 1 Reply Last reply Reply Quote 0
                                    • S
                                      SirBoyce @line last edited by

                                      @line I tried all of the above. The problem appears to be pretty much all to do with the Sell trailing stop loss aspect of the EA not firing as I should for no reason I can work out

                                      1 Reply Last reply Reply Quote 0
                                      • S
                                        SirBoyce @trader.philipps last edited by

                                        @trader-philipps Thanks. I set the test to a 5 spread, and the GBP/USD test still messes up because of the SELL trade not having a S/L (that is one without the SL you mentioned).

                                        Looking at my EA project, and based upon a spread of 4-5 pips, could you suggest how to calibrate the stop loss parameters to compensate?

                                        S 1 Reply Last reply Reply Quote 0
                                        • S
                                          SirBoyce @SirBoyce last edited by

                                          @sirboyce FYI, these are the test reports over period 2nd - 28th September 2019 (spread set to 5, 0.2 lot size)

                                          EUR/USD

                                          0_1569846328681_777ff75a-88e6-49b5-a97c-0b2c98ceb1a3-image.png

                                          EUR/GBP
                                          0_1569846362657_fa649edb-8eef-473c-b27a-04c3ee927ed2-image.png

                                          USD/CHF

                                          0_1569846420553_f2cb5941-19a8-4335-b820-a324c87e87a8-image.png

                                          Appreciate your comments.

                                          1 Reply Last reply Reply Quote 0
                                          • roar
                                            roar last edited by roar

                                            Hi. I'm just dropping here without knowing all the details of the project, but in general I have found out that backtests with some 50 trades contain zero information on actual profitability. You should test longer periods to get more reliable results. My rule of thumb is at least 200 trades per test.

                                            In my opinion, mt5 has a far better environment for developing and backtesting, but unfortunately that is too big a transition for most people..

                                            Need small help? Tag me in your post
                                            Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

                                            1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 2 / 2
                                            • First post
                                              Last post

                                            Online Users

                                            A
                                            F

                                            9
                                            Online

                                            146.7k
                                            Users

                                            22.4k
                                            Topics

                                            122.6k
                                            Posts

                                            Powered by NodeBB Forums | Contributors