fxDreema

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

    How to Make EA trade Engulfing candle

    Questions & Answers
    4
    10
    7049
    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.
    • L
      luckybest last edited by

      Hello fellow traders,
      I was trying to build an EA that will open trade base on Engulfing candle

      0_1557504844611_2019-05-10 at 17-10-12.png

      Here is my setup, I want to know if am correct, and if not I will gladly wecome any one show me way ...

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

        @luckybest
        I am not 100% on this but I believe you need to specify the opens and closes with more blocks.
        A body size > another body size doesn't mean it is engulfing, it could be larger in nature but greater in pips and be "true" but not engulfing.

        I think it needs to be something like;

        Bearish Engulfing
        Block 1-
        candle 2 close < (below) candle 1 open

        Block 2-
        Candle 2 open > (above) candle 1 close

        But then you can also go further and say

        Candle 2 close == to candle 1 open
        But if true
        Candle 2 open must be > candle 1 close
        Visversa

        And all need to be met so this would automatically indicate candle 1 is bearish abd the body needs to greater than either side of candle 2.

        If this doesn't work I am sorry. I am learning myself.
        But don't be afraid to test yours and this on strategy tester. No harm

        All the best

        L 2 Replies Last reply Reply Quote 1
        • L
          luckybest @surachefx last edited by

          @surachefx Thanks Appreciated I will try it.

          And If anyone with another Idea still welcome ... we are all learning

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

            @surachefx is correct, you need to specify more of the parameters of the engulfing pattern. In your post the conditions will pass if the body of candle 1 is greater in size than the body of candle 2, but this is only one of the characteristics of an engulfing pattern for Bearish Engulfing and there could be circumstances where these conditions are true but there is no engulfing pattern.
            When creating an EA that trades candle patterns (or any EA for that matter) I find it useful to write down all of the characteristics of the pattern, in a similar way as @surachefx has done above and then identify how fxDreena logic can be used to describe these characteristics. This software is powerful and extensive so there will almost always be more than one way to write an EA to perform a particular task. Running the EA in strategy tester or a demo account and watching it will almost certainly reveal things missed e.g. it picks up too many signals because we haven't specified the minimum size of the candles for the engulfing pattern to be valid.
            There is a lot of infomation on this Forum and a quick search on candle patterns will reveal a wealth of information others have already shared.

            L 1 Reply Last reply Reply Quote 1
            • L
              luckybest @CPBonzo last edited by

              @cpbonzo nice and informative comment.
              Thanks

              1 Reply Last reply Reply Quote 1
              • L
                luckybest last edited by

                I appreciate all your efforts.
                now I was able to search through the forum and came across what you told me to do.

                0_1557725623343_2019-05-13 at 06-25-47.png

                now, here is my challenge, I want to connect block 2 to 9 and block 3 to 15 additional condition to this block Like MA.
                I connect it directly but not working

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

                  The Pass block does nothing except trigger the next block to execute and if you connected the chain of blocks to the No Trade block, for example, you would not need the Pass block at all.
                  To answer your question, you would need to place any additional condition block after the Pass block. As to where, it depends in what order you need things to happen and how often conditions should be checked or action taken. As I suggested, it is good idea to write on a piece of paper the logic of the EA you are designing so you can see the order and then structure the fxDreema blocks to do this. If, for example, you want the conditon in your block 2 to occur before an engulfing bar then place it before the other conditions. Where you place it in relation to the Once Per Bar block depends on how you want the EA to function. Without that block the condition will be checked every tick and passed once the conditions are met therefore activating the next block. The Once Per Bar block in this set up means that the following conditions will only be checked once per bar (as it says) and this is usually at the start of the bar regardless of how many ticks there are. If the conditions are met later in the bar the conditions will not pass until the next bar, assuming the conditions remain the same.
                  If you remove the once per bar block and, for example, connect your block 2 above the condition blocks 5 and 6 the EA will check for your condition every tick and once passed will check for an engulfing candle as long as your condition is met and every tick all the conditions ar emet it will send an alert and draw an arrow. If you place the Once per bar block betwen the last condition and the alert and arrow blocks these events will only occur once per bar however many times the conditions pass per bar.

                  L 1 Reply Last reply Reply Quote 1
                  • L
                    luckybest @CPBonzo last edited by

                    @cpbonzo excellent job, It works perfectly as I followed the explanation
                    thanks so much

                    1 Reply Last reply Reply Quote 0
                    • L
                      luckybest @surachefx last edited by

                      @surachefx you are the best, it works

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

                        Me ajuda ai cara, estou criando umas ideias aqui

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

                        Online Users

                        E
                        J
                        T
                        J
                        B

                        17
                        Online

                        146.7k
                        Users

                        22.4k
                        Topics

                        122.6k
                        Posts

                        Powered by NodeBB Forums | Contributors