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

Volume multiplier

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

    Volume multiplier

    Hi Ninjatraders,

    Would this be programmatically correct in NT8:

    Volumes[1][0] < Volumes[1][1] * 2

    I am trying to say that Currently developing(not closed yet) bar volume on [1] dataseries is lower than 2x volume of previous bar of the same dataseries.
    Thank you

    #2
    Hello Paco0,

    Thanks for your post.

    Yes. You can always use print statements to verify the values.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Hi Paul,

      Thank you for such a quick response.

      One follow-up question please:
      Say I have 5 different dataseries in my code. It should not matter which dataseries is being processed for above to be calculated, since I specify index [1] for [1] dataseries.
      Or should I be setting BarsInProgress == 1 in this case?

      My understanding is that even if OnBarUpdate executes 5 times for each one of dataseries, values should always be the same.
      Would that be correct?

      Thanks a lot,

      Comment


        #4
        Hello Paco0,

        Thanks for your reply.

        Yes, that is correct, you are specifically pulling the volume data from the 1st added data series. You can verify this through print statements.

        For further clarity on what is being accessed in the different calculate modes, please see the help guide section, "How Bar Data is Referenced" https://ninjatrader.com/support/help...nstruments.htm
        Paul H.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by helpwanted, Today, 03:06 AM
        0 responses
        3 views
        0 likes
        Last Post helpwanted  
        Started by Brevo, Today, 01:45 AM
        0 responses
        7 views
        0 likes
        Last Post Brevo
        by Brevo
         
        Started by aussugardefender, Today, 01:07 AM
        0 responses
        5 views
        0 likes
        Last Post aussugardefender  
        Started by pvincent, 06-23-2022, 12:53 PM
        14 responses
        242 views
        0 likes
        Last Post Nyman
        by Nyman
         
        Started by TraderG23, 12-08-2023, 07:56 AM
        9 responses
        384 views
        1 like
        Last Post Gavini
        by Gavini
         
        Working...
        X