Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Count Number of bars/Time Period

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Count Number of bars/Time Period

    I am trying to count the number of bars created in a Renko chart over X period of time. For example, how many Renko bars are created (on average or over the past time period) within 30 mins duration. Is there a way/indicator to achieve that? I am not a programmer.

    Thanks!

    #2
    Hello kempotrader,
    Thanks for your post.

    There is a TickCounter and BarTimer available as a default indicator but not a BarCounter. You may want to search the forum and/or our file sharing section for this. Otherwise, to accomplish this you would need to use some custom programming
    Josh G.NinjaTrader Customer Service

    Comment


      #3
      Thought so. Thanks

      Comment


        #4
        kempotrader

        did you ever overcome this issue ?

        I am looking for he same, to alert a trading frenzy when 40 renko bars are printed in less than 30 seconds

        Comment


          #5
          No, DTSSTS. I wound up leaving it behind. Still like the idea though. I have fond success with defining "extended" and waiting for confirmation on a return to the mean. I am a countertrend trader.

          Whishing you Success!

          kempo

          Comment


            #6
            Thanks for the response, the is a barcounter indicator on the forum which you probably saw

            Al Brooks style Bar Counter which places the number of the bar below every other bar starting at 1 for the first bar of each session. You can change the text size, color, place text below or above price bars, change the distance below/above a price bar, show either odd or even numbers.


            I cant wrap my head around using with a time value for rapid change in the bar counter

            My purpose to count the bars in a very short time period, for example 40 bars in 30 seconds to actually in auto trade program to block trades for a short period of time, I do this with spreads on stocks (not counting bars) which could be used but on MNQ for example the norm is 2 3 tick spread, but spikes to 6-9 are common, but general are only on 1 intrabar renko type bar and NOT multiple bars

            good trading

            Comment


              #7
              Good morning--

              I had not seen that bar counter (or don't remember it). Jigsaw has a Pace of Trade gauge that might do the trick. It would be expensive to find out if it's what you're looking for, though. It's specific to time and sales, not any bar type.

              I'm actually going live with MNQ this morning. That sucker moves! I like the short duration trades.

              Comment


                #8
                short duration as well here, Tepper really moves markets

                Comment


                  #9
                  Hello DTSSTS,

                  Just want to confirm, you are looking for a finished importable product and you are not inquiring about information of how to count bars in an unlocked NinjaScript indicator, is this correct?
                  Chelsea B.NinjaTrader Customer Service

                  Comment


                    #10
                    i am looking to add code to my strategy to count bars (renko type brick driven) in a short time frame, possible comparing time of last 40 bars being in that very short time value comparision

                    Comment


                      #11
                      I'd be very interested if that became available.

                      Btw... My live MNQ opening trade had a duration of 14sec...lol So fast.

                      Comment


                        #12
                        Hello DTSSTS,

                        Would you like to move this conversation to the NinjaTrader 8 Strategy Development section of the forum?


                        A bar number can be found with the time with Bars.GetBar().


                        You can subtract to get the number of bars.
                        Bars.GetBar(endBarTime) - Bars.GetBar(startBarTime)


                        Or you can have an integer that counts on each bar close (or when IsFirstTickOfBar) is true to count the number of bars since some condition was true.
                        Chelsea B.NinjaTrader Customer Service

                        Comment


                          #13
                          thanks i will work with that endBarTime to see what i can get, looks promising

                          Comment

                          Latest Posts

                          Collapse

                          Topics Statistics Last Post
                          Started by jeronymite, 04-12-2024, 04:26 PM
                          3 responses
                          43 views
                          0 likes
                          Last Post jeronymite  
                          Started by frankthearm, Today, 09:08 AM
                          4 responses
                          10 views
                          0 likes
                          Last Post frankthearm  
                          Started by yertle, Today, 08:38 AM
                          5 responses
                          15 views
                          0 likes
                          Last Post NinjaTrader_BrandonH  
                          Started by adeelshahzad, Today, 03:54 AM
                          3 responses
                          18 views
                          0 likes
                          Last Post NinjaTrader_BrandonH  
                          Started by bill2023, Yesterday, 08:51 AM
                          6 responses
                          27 views
                          0 likes
                          Last Post NinjaTrader_Erick  
                          Working...
                          X