fxDreema

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

    after closing profitable trades, Wait for remaining trades to profit before closing?

    Questions & Answers
    6
    17
    3297
    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.
    • W
      wralyn last edited by

      hello there guys! first of all I want to say im very happy to be a part of the FxDreema community!

      I have been waiting to pull the trigger for some time now and i am glad i did! these tools have made the job
      of creating excellent forex ea's simply amazing and fast.

      I have a question about how i would structure a certain logic into my ea , but first i want to post a shared link to my ea for those more advanced that don't care for my explantion of the logic.

      https://fxdreema.com/shared/goneOZ93b

      so in order for my question to make sense first i need to explain the objective and logic of this ea i have named
      "close the gap" for simplicity.

      I have created a very basic ea, my first one, and the logic is very simple and profitable in my testing.

      So the premise is the when the 100 ema is below the 500 ema, the ea will wait for a candle to close above the 100 ema then it will open a buy order. (vice versa for sells) . it will open a buy order every time this condition is met.

      then it will wait for a candle to touch the 500 ema and it will close all open buy orders.

      here is where my question comes in.

      80 percent of the trades will close profitable when a candle touches the 500 ema, but sometimes a couple will close slightly negative. What i want to do is have the ea close all profitable trades when when the candle touches the 500 ema, then go into a wating period on the remaining trades and close them as soon as they are in any kind of profit or break even, accounting for spread plus commision ect. Basically as soon as the trades are not losers, i want to ea to close them.

      Does any one have an obvious logic chain or solution to this, I'm assuming im not the first person to ask this, but ive looked around the forum and can't seem to find the answer i'm looking for.

      I would greatly appreciate any insight into this query. and its totally ok if you don't . I still love ya! thanks again.

      https://fxdreema.com/shared/goneOZ93b

      1 Reply Last reply Reply Quote 0
      • W
        wralyn last edited by

        anybody have a clue?

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

          Substitute your current 'close trade' paths for this (buys only)

          https://fxdreema.com/shared/9G4rdekBb

          Not tested, but that should work.

          (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.

          W fxDreema 2 Replies Last reply Reply Quote 0
          • W
            wralyn last edited by

            @l-andorrà thank you I will give this a shot!

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

              @l-andorrà thank worked really well thank you so much for your help, you really know what you are doing don't you?

              N 1 Reply Last reply Reply Quote 0
              • N
                Nacim @wralyn last edited by

                @wralyn watch out your bot without a stop loss could be dangerous if your conditions are not met

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

                  @l-andorrà said in after closing profitable trades, Wait for remaining trades to profit before closing?:

                  Substitute your current 'close trade' paths for this (buys only)

                  https://fxdreema.com/shared/9G4rdekBb

                  Not tested, but that should work.

                  This is strange. The first 2 blocks are working for the loop - some trade is selected and we reach block 3 when that trade is profitable. But then block 3 is a condition. When the first block runs, it will load the first available trade, then run block 2... after a moment it will load the second available trade, then run block 2 again... but this all happens as quickly as possible. The only thing that slows the whole loop is block 4, because when you close a trade, it takes second or two.

                  Then this blue block is strange to me. Why not the pink "close" block?

                  The whole thing looks to me that you are trying to initiate the closing procedure, assuming that while the trades are being closed, some time can pass and the MA values could change. This is strange. I'm also not sure if wralyn was asking for that, but I don't telly understand what he means. I have some feeling that he wants to delete the currently profitable trades and "mark" the rest for deletion at a future time, maybe not caring about 500 ema anymore.

                  1 Reply Last reply Reply Quote 0
                  • W
                    wralyn last edited by

                    You are absolutey right FxDreema, What i was asking for is when the price hits the 500 ema, close all the trades that are profitable at the 500 ema, then for the trades that are not profitable at the 500 ema, what for price to move a bit further than close them at break even or small profit. i decided to add this after back testing showed the price usually moves beyond the 500 ema once it is hit, and most of the unprofitable trades just need the market to move a small percentage more to be profitable.

                    I'm a beginer at using the FxDreema software, but the premise seems valid to me. And after testing the new EA results for the last 6 months of trading have been very profitable.

                    If there are ways to improve the EA i'm definitely listening.

                    Here is what i ended up with after implementing the changes suggested.

                    https://fxdreema.com/shared/hDNUrsHub

                    1 Reply Last reply Reply Quote 0
                    • W
                      wralyn last edited by

                      Also what i have found is that 1hr time frame yields the best results in my testing, if you go down in time frame the moving averages need to larger, and if you go up in time frame they need to be smaller to get similar results.

                      the only problem is that the Ea does not loose trades, i ran a test and over 200 trades in a row are winners over 6 months, so if market gets out of hand or a runaway trend occurs could be trouble as Nacim mentioned.

                      1 Reply Last reply Reply Quote 0
                      • D
                        dscoles last edited by

                        Running your little EA is a heady experience! Something so SIMPLE works extremely well. Very nice algorithm. Thank you for sharing.

                        1 Reply Last reply Reply Quote 0
                        • D
                          dscoles last edited by

                          Hello wralyn,
                          May I suggest that one small change could possibly help with drawdown and long-term open positions at the same time. You could try adding another parameter to your protocol which would be a minimum pips (such as 10 pips) as a separation between the EMA 100 and the EMA 500. Seems to work like a charm.

                          F 1 Reply Last reply Reply Quote 0
                          • F
                            fideld003 @dscoles last edited by

                            @dscoles How do you do this one? This may help in the project I am doing.
                            Hi @l-andorrà any thoughts on this as well? Thanks.

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

                              @fideld003 What do you exactly need?

                              (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
                              • F
                                fideld003 last edited by

                                @l-andorrà Per the suggestion of @dscoles, "May I suggest that one small change could possibly help with drawdown and long-term open positions at the same time. You could try adding another parameter to your protocol which would be a minimum pips (such as 10 pips) as a separation between the EMA 100 and the EMA 500. Seems to work like a charm."

                                @l-andorrà I'm trying to think how to do the suggestion of @dscoles, but I could not wrap my head around it.
                                Thank you for the response.

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

                                  @fideld003 You can insert a minimum distance between EMAS this way (for buys only):

                                  0_1608567398942_01.png

                                  You should reverse both EMAs positions for a sell.

                                  (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
                                  • F
                                    fideld003 last edited by

                                    @l-andorrà awesome stuff! Thank you for showing this to me. I'll try this minimum distance check on my project. I really appreciate it.
                                    @dscoles thank you for the tip. Hope you're doing okay. 🙂

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

                                      @fideld003 You're welcome.

                                      (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
                                      • 1 / 1
                                      • First post
                                        Last post

                                      Online Users

                                      C
                                      I
                                      I
                                      E
                                      E
                                      O
                                      O
                                      D
                                      F
                                      K

                                      41
                                      Online

                                      146.6k
                                      Users

                                      22.4k
                                      Topics

                                      122.6k
                                      Posts

                                      Powered by NodeBB Forums | Contributors