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

Reproducing renko chart from tick data

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

    Reproducing renko chart from tick data

    Hi there,
    I am attempting to reproduce the renko the chart from tick data for ZN 09-17. Now I did my best to look around here before posting so you will need to forgive me as this might have already come up elsewhere I am sure. Both charts are based on 4-tick bricks. In my external code, I employed the simple algorithm of forming new bars whenever the price went 4 ticks above the previous brick's top edge, or when the price went 4 ticks below the previous brick's bottom edge. My results are not caputuring as much as price activity as the results given in NT. I am aware I am not really asking a specific question but I would certainly appreciate some suggestions or to be pointed to material within the forum that already dealt with issues regarding reproducing renko bars from data. Thank you.
    Pedro
    Attached Files

    #2
    Hello pedromoy,

    Thank you for your post.

    What is your logic for your external Renko bars as written in code or a formula?

    Have you reviewed the logic of the Renko bars in NinjaTrader? Go to the Control Center > New > NinjaScript Editor > BarsTypes > RenkoBarsType.

    I look forward to your response.

    Comment


      #3
      Hi Patrick,
      Thanks for your reply. I will take a look at the source script, thanks for sharing. All the while, I also checked thinkorswim's renko chart and was able to match that to my external result perfectly. There are some things about NT's chart that I am not sure about and seem to differ a bit from my two matching charts (my own source code using tick data from Continuum and TOS's). Like for instance what appears to be empty bar slots and others (I have highlighted those in the chart attached).

      My python script main's logic loop follows as:


      Here is my renko chart:


      Here is TOS's matching chart:


      And here is NT's charts with highlights:


      Hopefully, this is just a configuration issue (I am nwe to NT and am still learning the platform). Thanks for your help.

      Pedro

      Comment


        #4
        Hello pedromoy,

        Thank you for your response.

        Please right click in your NinjaTrader 8 chart > select Data Series > unchekc the option "Break at EOD" > OK.
        Does this chart now match what you see on your chart and in TOS?

        I look forward to your response.

        Comment


          #5
          Yes, perfect, everything matches now.
          Pedro

          Comment


            #6
            Hi Pedromoy

            Interesting post.

            Can I ask you where you get the tick data?

            I am also working on plotting renkos in python, but I only have 1min candles to work with.

            Do you think you can get a good approximation on that basis?

            Thanks and good luck
            David

            Comment


              #7
              Originally posted by pedromoy View Post
              Hi Patrick,
              Thanks for your reply. I will take a look at the source script, thanks for sharing. All the while, I also checked thinkorswim's renko chart and was able to match that to my external result perfectly. There are some things about NT's chart that I am not sure about and seem to differ a bit from my two matching charts (my own source code using tick data from Continuum and TOS's). Like for instance what appears to be empty bar slots and others (I have highlighted those in the chart attached).

              My python script main's logic loop follows as:


              Here is my renko chart:


              Here is TOS's matching chart:


              And here is NT's charts with highlights:


              Hopefully, this is just a configuration issue (I am nwe to NT and am still learning the platform). Thanks for your help.

              Pedro
              Dear ,
              Can you please share the code file or the full Renko code in python .I am developing some algorithm for which this code is really required.

              Comment


                #8
                Originally posted by Bakalok View Post
                Hi Pedromoy

                Interesting post.

                Can I ask you where you get the tick data?

                I am also working on plotting renkos in python, but I only have 1min candles to work with.

                Do you think you can get a good approximation on that basis?

                Thanks and good luck
                David
                Hi David,
                I get tick data through NT brokerage. As you know, these renko charts measure price displacement, and how fast you need to react to these displacements ultimately dictates whether or not you are ok working with 1-min-candles. Say you're looking at weeks to months worth of data, and you certainly don't care about minutes, then minute scale data could be a reasonable approach. That's my two cents, hope it helps.
                Pedro

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by mjairg, 07-20-2023, 11:57 PM
                3 responses
                213 views
                1 like
                Last Post PaulMohn  
                Started by TheWhiteDragon, 01-21-2019, 12:44 PM
                4 responses
                544 views
                0 likes
                Last Post PaulMohn  
                Started by GLFX005, Today, 03:23 AM
                0 responses
                3 views
                0 likes
                Last Post GLFX005
                by GLFX005
                 
                Started by XXtrader, Yesterday, 11:30 PM
                2 responses
                12 views
                0 likes
                Last Post XXtrader  
                Started by Waxavi, Today, 02:10 AM
                0 responses
                7 views
                0 likes
                Last Post Waxavi
                by Waxavi
                 
                Working...
                X