Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Custom Volume Profile based on Trading hours Template

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

    Custom Volume Profile based on Trading hours Template

    I have a Custom Volume Profile Indicator that plots daily session volume profiles. However, I want the sessions based on the Trading Hours Template. Please help.
    Last edited by Nyman; 07-28-2024, 02:24 PM.

    #2
    Hello Nyman,

    A script will use the data of the chart, which is controlled by the Trading Hours template selected in the DataSeries. Any added series will also use that Trading Hours template unless it is a different instrument.

    With AddDataSeries() you can specify a Trading Hours template.
    AddDataSeries(string instrumentName, BarsPeriod barsPeriod, string tradingHoursName)


    Note, using branching commands or variables with AddDataSeries() to call this dynamically is not supported.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      NinjaTrader_ChelseaB, Thanks for your time and response. Is this the only change I have to make to the file attachment? I can easily do that.

      Comment


        #4
        Hello Nyman,

        Yes, a data series only uses the data made available from the trading hours template.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Click image for larger version

Name:	after.png
Views:	210
Size:	145.6 KB
ID:	1311905 Click image for larger version

Name:	before.png
Views:	173
Size:	142.7 KB
ID:	1311906 Hello Chelsea, unfortunately, that solution didn't work for me.
          Last edited by Nyman; 07-26-2024, 12:09 PM.

          Comment


            #6
            Hello Nyman,

            Yes, a data series only uses the data made available from the trading hours template.

            Are you certain the script is only using data from BarsInProgress 1 / BarsArray[1]?
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              Hello Chelsea,

              Yes, I'm certain. The issue has been resolved. After understanding the original logic behind it, I had to make certain changes to the script and it worked. Thanks for your tremendous help.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by CarlTrading, 03-31-2026, 09:41 PM
              1 response
              47 views
              0 likes
              Last Post NinjaTrader_ChelseaB  
              Started by CarlTrading, 04-01-2026, 02:41 AM
              0 responses
              22 views
              0 likes
              Last Post CarlTrading  
              Started by CaptainJack, 03-31-2026, 11:44 PM
              0 responses
              33 views
              1 like
              Last Post CaptainJack  
              Started by CarlTrading, 03-30-2026, 11:51 AM
              0 responses
              50 views
              0 likes
              Last Post CarlTrading  
              Started by CarlTrading, 03-30-2026, 11:48 AM
              0 responses
              42 views
              0 likes
              Last Post CarlTrading  
              Working...
              X