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

RTH close volume

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

    RTH close volume

    NT7 scenario:

    I have a chart which uses the ETH Session. I want to capture only the RTH close volume.

    Question:

    The only way I can think to capture this is to hard-code the RTH close time range I want using exchange time. I couldn't figure out a way to get the RTH close time unless I use the RTH session template.

    Wasn't sure if there was a better or easier way to do this? It is not difficult I am just not a fan of hard coding so didn't didn't know is a place I can retrieve it from somewhere within Ninja.

    Cheers

    #2
    Who are you connected to? This is displayed in green on lower left corner of the Control Center window.

    What interval is your chart? For example, 5 minute, 1 day, 150 tick, 4 range, etc.

    Comment


      #3
      Patirck

      I am connected to continuum. I have a secondary 1 tick added time frame to disassociate from the time frame displayed. I know I can use calculate on bar close = no but it is more bullet proof this way as bar close cannot be forgotten to be set or accidentally set off.

      Cheers
      Last edited by ct; 05-22-2017, 10:35 AM.

      Comment


        #4
        I'd like to make sure I understand what you're trying to accomplish. Please correct me if any of the below is not the case:

        You want to have a chart which displays ETH bars
        You want that same chart to show RTH volume (what interval? Daily? The same as the primary data series? What is the interval of the primary data series?)

        Comment


          #5
          Patirck

          I want my indicator to capture the ticks of the close without having to hard code those exchange times in the indicator to know which ticks to capture.

          I guess a better way to put it is there way to determine the range of another session template definition other than the one you have assigned to the chart? I am guessing "no".

          Can I read/retrieve a session template definition?
          Last edited by ct; 05-22-2017, 11:34 AM.

          Comment


            #6
            Thank you for your question ct. Please bear in mind that NinjaTrader 7 is no longer under active development and any solution we come up with will need to be at the NinjaScript level.

            Bars.Session contains information including the beginning and ending times for a session.



            While this is untested and not directly supported and not guaranteed to work in current or future versions of NinjaTrader, Session objects have previously been creatable programmatically via

            Code:
            Session.String2Session("Default 24/7");
            Replace Default 24/7 by your session name to check. Please let us know if there are any other ways we can help.
            Jessica P.NinjaTrader Customer Service

            Comment


              #7
              Jessica

              Duh. Didn't catch your reply straight off.

              Going to ask, any rumors on an NT8 conversion tool?

              Cheers

              ps: like the disclaimer.
              Last edited by ct; 05-22-2017, 12:06 PM.

              Comment


                #8
                I am happy to help. I am testing the solution I provided in post #5 and will return shortly with a code sample for NT7 that should allow us to programmatically test for session beginning and end by session name, using ETH and RTH as an example.

                With respect to conversion tools, an attempt was made when Ninja 8 was in Beta to create such a tool, and this attempt can be found here.



                It is likely that the author of this tool or some of the other forums members who collaborated can be reached via private message.
                Jessica P.NinjaTrader Customer Service

                Comment


                  #9
                  Jessica

                  I have said it before and will say it again you are a star!

                  Cheers

                  Comment


                    #10
                    Attached is a code sample that should do something like what you are describing. Code samples we provide are for educational purposes, and are not intended for live trading, and are not guaranteed to accomplish any user goal or to be maintained.
                    Attached Files
                    Jessica P.NinjaTrader Customer Service

                    Comment


                      #11
                      Jessica

                      It works perfectly and just what I requested. Unfortunately I discovered in my testing most contracts close out at the end of open out cry not the actual session end time but I can just adjust the extracted RTH time by 15 minutes. So it still works just fine.

                      Cheers
                      Last edited by ct; 05-24-2017, 04:36 AM.

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by Christopher_R, Today, 12:29 AM
                      0 responses
                      6 views
                      0 likes
                      Last Post Christopher_R  
                      Started by sidlercom80, 10-28-2023, 08:49 AM
                      166 responses
                      2,235 views
                      0 likes
                      Last Post sidlercom80  
                      Started by thread, Yesterday, 11:58 PM
                      0 responses
                      3 views
                      0 likes
                      Last Post thread
                      by thread
                       
                      Started by jclose, Yesterday, 09:37 PM
                      0 responses
                      7 views
                      0 likes
                      Last Post jclose
                      by jclose
                       
                      Started by WeyldFalcon, 08-07-2020, 06:13 AM
                      10 responses
                      1,415 views
                      0 likes
                      Last Post Traderontheroad  
                      Working...
                      X