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

Problems on PriorDayOHLC().PriorClose[0]

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

    Problems on PriorDayOHLC().PriorClose[0]

    Hi

    the below is the code, but when I try to print out the Close of ES. The number is very different from the close. Can you advise on any setting? FYI, my default session ends 04:15.

    thx

    Add("ES 09-10", PeriodType.Minute, 5);

    if (BarsInProgress == 1)
    {
    //ES_INT = Close[CurrentBar - Bars.GetBar(new DateTime(4,15,0))];
    ES_INT =PriorDayOHLC().PriorClose[0];

    #2
    Hi NingNing,

    Let's take a step back, does that call work on your primary series, in a single series script?
    TimNinjaTrader Customer Service

    Comment


      #3
      yes, I realize that these 2 instrument in different time zone, may be I can not ge the priorsession on 2 different time zone, any suggestion of code how to get the current session close()?

      Comment


        #4
        Hi NingNing,

        What primary series, and Session Templates are you using? I'd like to test this on my end.
        TimNinjaTrader Customer Service

        Comment


          #5
          hI

          I am trying HSI 07-10 and ES 09-10, please let me know if you get it and how you set the session for these elements, many thanks

          Comment


            #6
            Hi NingNing,

            Unfortunately I do not have a subscription to that instrument to test.

            Why are you suspecting the time-zones?
            Have you tried this on other instruments? With the same time-zone or differing ones?
            TimNinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by CortexZenUSA, Today, 12:53 AM
            0 responses
            1 view
            0 likes
            Last Post CortexZenUSA  
            Started by CortexZenUSA, Today, 12:46 AM
            0 responses
            0 views
            0 likes
            Last Post CortexZenUSA  
            Started by usazencortex, Today, 12:43 AM
            0 responses
            2 views
            0 likes
            Last Post usazencortex  
            Started by sidlercom80, 10-28-2023, 08:49 AM
            168 responses
            2,262 views
            0 likes
            Last Post sidlercom80  
            Started by Barry Milan, Yesterday, 10:35 PM
            3 responses
            10 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Working...
            X