Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Single Price Bars

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

    Single Price Bars

    I'd like to use a bar type that aggregates all consecutive same price ticks together, then changes to a new bar (actually just a new data point) when the price level changes, then starts aggregating all ticks at the new price level until a new price level occurs, etc.

    Conceptually it's something like a 0 (zero) range bar plotted as a zigzag. Volume, trade count, and cumulative delta calculations should be possible for each bar.

    I've attached a quick example of its construction mocked up in excel.

    Can anyone point me in the right direction if it already exists, or suggest a resource for coding it?

    Many thanks!








    #2
    you describe 1 tick chart

    Comment


      #3
      thanks nkhoi for the response. here's a screenshot of a 1-tick chart in NT8. it shows multiple ticks (trades) at the same level. i want all the ticks at the same level to be contained in 1 tick. so in the case of the screenshot there would be only 3 ticks showing: one for each price level (2587.25, 2587.00, 2586.75).

      Comment


        #4
        What about a 1 range bar?

        Comment


          #5
          hi captain future, thanks for the suggestion. attached is a screen shot of a 1 range bar. each bar has 1 range between 2 ticks.

          Comment


            #6
            Hello dave01,

            Thank you for the post.

            For what you are explaining, I believe the closest to the description would be a 1 range bar as Captain Future noted however what you have detailed is essentially a 0 range bar.

            You would likely need to create a BarsType to accomplish this. The existing Range BarsType could be used as a starting point, its Range input specifically has a hard limit of 1 which you could remove as a starting point. You would likely need to go through the logic in the existing bars type to make sure it still makes sense in contrast to using 0 range to break bars. You can use the NinjaScript editor to view the existing BarsTypes code.

            I look forward to being of further assistance.
            JesseNinjaTrader Customer Service

            Comment


              #7
              thanks jesse, i'll give it a try!!

              Comment


                #8
                Greetings. Did you manage to create this type of bars?

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by rtwave, 04-12-2024, 09:30 AM
                4 responses
                30 views
                0 likes
                Last Post rtwave
                by rtwave
                 
                Started by yertle, Yesterday, 08:38 AM
                7 responses
                29 views
                0 likes
                Last Post yertle
                by yertle
                 
                Started by bmartz, 03-12-2024, 06:12 AM
                2 responses
                22 views
                0 likes
                Last Post bmartz
                by bmartz
                 
                Started by funk10101, Today, 12:02 AM
                0 responses
                6 views
                0 likes
                Last Post funk10101  
                Started by gravdigaz6, Yesterday, 11:40 PM
                1 response
                9 views
                0 likes
                Last Post NinjaTrader_Manfred  
                Working...
                X