fxDreema

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

    If at least 2 of 3 conditions are met..

    Questions & Answers
    3
    14
    1410
    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.
    • E
      equinox last edited by

      I have defined 3 variables that are each set to 1 (int) when the 3 respective conditions give a positive signal. My strategy requires that at least 2 of the 3 conditions are met. Normally I would define a 4th variable that is the sum of the other 3. Thus, if that variable is >1, the strategy would be executed. I just cannot find a function which would allow this, and would be glad for any suggestions.

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

        @equinox Sadly, you will need to use as many formula and conditions groups as required. There is no specific funtion doing that, sorry.

        (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
        • E
          equinox last edited by equinox

          If have tried again to solve the problem above with variables that are set to 1 if the respective condition is met (blocks 5-7), and another variable ("sum") that is the sum of the first 3 variables.

          In block "2 of 3" I have tried to define that the the sum should be > 1 (meaning at least 2 of 3 conditions are met). The code is executing, but there is no arrow printed where there should be one.

          https://fxdreema.com/shared/QeAFIWNKd

          I have also tried to achieve the same result with AND/OR expressions, but I think I need to hyphenate some blocks together, which I am not sure can be done:

          Condition0 (Blocks 1-4) AND

          (Condition1 AND Condition2) OR
          (Condition1 AND Condition3) OR
          (Condition2 AND Conditon3)

          My apologies for the many edits.

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

            It is unclear from the EA you shared where the variable "sum" is adjusted such that it is the sum of the other variables. Also unclear why you are using the custom MQL block (which isn't doing what you think it is doing anyway) when the condition block could be used to compare the "sum" variable to a value.
            It is generally best to set the candle id to 1 (the previously completed candle) as the value during the current candle will change frequently.
            How are you re-setting the variables if conditions are no longer met?

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

              @equinox You are working on candle ID 0 whereas your condition blocks are limited to 'once per bar' on top. Remove that block on top and you will get many arrows.

              (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
              • E
                equinox last edited by

                @CPBonzo and @l-andorrà Thank you both for your comments. I will try to incorporate all of the mentioned issues in my next version. Just for clarification, if I set candle id = 1, will this be the closing price of the last completed candle?

                1 Reply Last reply Reply Quote 0
                • C
                  CPBonzo last edited by

                  Yes, if you set the candle id to 1 the value obtained will be that when the last completed candle closed.

                  1 Reply Last reply Reply Quote 0
                  • E
                    equinox last edited by

                    @CPBonzo How can I use the condition block to compare to my "sum" variable? I cannot find anything about variables there. Could it work like this? 0_1596228275191_8c100217-773c-4250-b5eb-8e1d19c7a4bb-image.png

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

                      @equinox That 'Text(code input option)' is used to add mql4 code. That is not what you need. If you need a variable, you can create it and then use it on the left operand as usual.

                      (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
                      • E
                        equinox last edited by

                        I cannot find the "sum" variable, or the other ones I created in the dropdown menu:

                        0_1596377752555_7ef40dbf-1b66-4a02-bc34-c8f9f25aa138-image.png

                        I am probably getting this wrong somehow..

                        l'andorrà C 2 Replies Last reply Reply Quote 0
                        • l'andorrà
                          l'andorrà @equinox last edited by

                          @equinox Can you please detail what do you exactly need? Apparently you craeted a variable called 'sum' but what do you exactly need from it?

                          (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
                          • E
                            equinox last edited by

                            @l-andorrà The variable is defined as the sum of other variables:

                            sum = condition1+condition2+condition3

                            The conditions are either 1 (=true) or 0 (false).

                            If at least tow conditions are met (sum > 1), the block should have a positive output.

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

                              @equinox Then I suggest you to create two separated block trees. One cheking the conditions and a different one doing the sum. That way should simplify everything.

                              (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
                              • C
                                CPBonzo @equinox last edited by

                                @equinox Value is correct in this box. In the box where you have written "sum", simply right-click and you will be presented with a list of your variables and constants.

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

                                Online Users

                                S
                                T
                                A
                                Y
                                H
                                B

                                14
                                Online

                                146.7k
                                Users

                                22.4k
                                Topics

                                122.6k
                                Posts

                                Powered by NodeBB Forums | Contributors