fxDreema

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

    My Grid type EA project

    Questions & Answers
    3
    13
    5738
    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
      sunny7day last edited by sunny7day

      How to do this:

      1. If there is a buy trade and the price go against me in 10 pips, add another buy...and so on and on.
      2. Let says the markets go against me and opened 20 trades, but the market is now retracing. I want to close with 5 pips of profit(not money) of these 20 trades.
      M 1 Reply Last reply Reply Quote 0
      • M
        moreirajbn @sunny7day last edited by

        @sunny7day

        You may search the forum for "grid" or "grid trading" or "averaging" and you'll find many great answers....

        1 Reply Last reply Reply Quote 0
        • S
          sunny7day last edited by sunny7day

          I did but i can't find what i am looking for?

          M 1 Reply Last reply Reply Quote 0
          • M
            moreirajbn @sunny7day last edited by

            @sunny7day

            there is a block called "buy pending orders in grid".

            it will do exactly what you need.

            1 Reply Last reply Reply Quote 0
            • S
              sunny7day last edited by sunny7day

              Here is the "Buy Pending orders in grid" you said:
              0_1528769016715_2018-06-12 10.01.32.png
              Thank you but that is not what i am looking for. It does not place order at market price and it place orders at the wrong side. Also I don't really want to use pending order.

              I think i need to do it another way manually :
              Buy at price level, if against me X pips then Buy again with same lot size. Take profit is averaging 5 pips profit of all Buy orders. Just that, help me please.

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

                You can flip the grid by putting negative Grid size.

                If you want to do it manually,

                • when a trade is opened, store the price to some variable lastprice
                • formula: candle price - lastprice
                • condition: formula result is above X pips
                • open trade, change the price variable.

                I'm not sure about the average 5 pips closing, as I use netting system myself. I guess you can do it with the bucket of trades -block.

                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
                • S
                  sunny7day last edited by sunny7day

                  Thanks but sorry, I think i am totally stuck, not sure what to do now.
                  Actually I want to create a random direction Grid ea: Buy or Sell if no trade, if price go against me then add more trade, just that.
                  See this: https://fxdreema.com/shared/qCQmByUfb

                  1 Reply Last reply Reply Quote 0
                  • S
                    sunny7day last edited by

                    since there is no more help, i am willing to pay $10 to anyone who can help me to finish my EA.

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

                      https://fxdreema.com/shared/OG5F0mdB
                      Here's the core grid system as you described.

                      You can just open this into a new tab and then copy all blocks to your new project.
                      Remember to set constants and variables like this:
                      0_1528808539481_53d6bafb-8548-4b14-96b2-6b3abb1b587e-image.png
                      0_1528808548909_8ffc8770-7808-45d4-a700-762472ec8f68-image.png

                      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
                      • S
                        sunny7day last edited by sunny7day

                        Hello roar, thank you so much for your help! The money will be yours.

                        What if I want the EA start a random trade immediately after I attached the EA to the chart? Because I see that you are dealing with candle IDs, in this EA only price level should matter i think, why candle ID?

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

                          Oh, yes, I used the candle ID in just one block, others are id 0.
                          That one block is meant for randomization; it compares upper wick of candle 55 to candle 67 or something, the outcome is very random (50:50 buys and sells). That condition can of course be something else as random, or perhaps some custom random function.
                          Personally I would trade in direction of some long period moving average, its not random and its not perfect trading analysis, but it is something in between...

                          The ea will trade instantly you run it.

                          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
                          • S
                            sunny7day last edited by

                            Sir thank you for your work, I renamed variables and constance, and did some other changes. Here is my version:

                            0_1528814605136_2018-06-12 22.41.46.png
                            0_1528814635705_2018-06-12 22.41.53.png
                            https://fxdreema.com/shared/Ve9B1sI2c

                            Now it is just missing the take profit, I want averaging TP of all trades in pips.

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

                              https://fxdreema.com/shared/jX8wezXxc
                              This seems to work. I see fxdreema has implemented some nice new blocks, makes things easier 🙂

                              0_1529231575041_multicurrency.mq5

                              https://fxdreema.com/shared/LDVAFZSMd
                              0_1529308139027_7050fbbb-8e13-4fd5-a41d-2fdf34b07bfe-image.png
                              0_1529308148211_e4ca2926-56ac-4e24-8612-948aed4c614e-image.png

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

                              Online Users

                              O
                              D
                              F
                              K
                              C
                              E
                              M
                              F
                              T

                              21
                              Online

                              146.6k
                              Users

                              22.4k
                              Topics

                              122.6k
                              Posts

                              Powered by NodeBB Forums | Contributors