fxDreema

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

    counting bars that have been losing

    Questions & Answers
    2
    3
    412
    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.
    • A
      Ash12222222 last edited by

      Hello All,

      Sorry bnut I am new to this platform that I like a lot, I am trying to do a simple routine which only trades if it has seen 3 up bars in the last hour, any one have nay ideas?

      Thanks all.

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

        There is no special block to calculate this, but there is one block that can compare values in N candles - Indicator moves within limits. Yes, there is "indicator" in the name of this block, but whatever.

        https://fxdreema.com/shared/uF78pfrI

        Here block 4 should pass if in the 4 past candles (candles with IDs 1-to-4) at least 3 candles are bull. You can see in the properties that the block is set to look into the last 4 candles and allows exception of 1 candle.
        How we check for bull candle? Candle Close must be > Candle Open. As you can see, Candle Open is the lower level for this block. There is no upper level and that's why Candle Close can be even 10000

        Why 4 candles? I was working on M15 and 4 candles in M15 are 1 hour. I think you are working with this timeframe as well. Otherwise what is the point of searching for 3 bull candles in one hour in M5 or H1 🙂

        1 Reply Last reply Reply Quote 0
        • A
          Ash12222222 last edited by

          Thanks that is great.

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

          Online Users

          E
          E
          O
          S
          B
          M
          E

          15
          Online

          146.7k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors