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

New User Woes

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

    So close is the last trade and not the close of the bar??, i was trying to reference the last trade during a bar. like not the final last but like the last one a second agon during the current bar

    Comment


      If you are running CalculateOnBarClose = false (tick by tick) then Close[0] is the last trade. If you are running with it true, close of the bar, then this is the last trade since you can not access it intrabar since OnBarUpdate() is only called on the close of the bar.
      RayNinjaTrader Customer Service

      Comment


        How do you keep the arrows drawn on the charts to stay on the chart, mine draw like on the current bar then dissapear

        Comment


          Don't pass in the same tag value, make them unique such as

          string myTag = "downArrow" + CurrentBar;
          RayNinjaTrader Customer Service

          Comment


            k i will try that, so basically if i use a tag, for when the price moves up more than 2 dollars at the end of the day it would show an arrow everytime that occured right??

            Comment


              A unique tag will ensure that whenever you call any drawing method, you will get a unique instance of a drawn object.
              RayNinjaTrader Customer Service

              Comment


                Thanks for the help guys, I do have another quesdtion i have been trying to get figured out,

                I know there is the indicator with the open high and low of the session, but the problem i have is if i set the sessin to begin at 8:30am the cahrts are messed up becuse i dont have the data before 8:30 am. so i usually will have the session begin at 12:00 am to 12:00am. What i would like is the same indiactor but to draw the lines from the open at 8:30am instead of 12:00am. I havent been able to figure out how to make it draw the lines at 8:30 am instead of session beginning

                Comment


                  You would have to figure out the bar index of the 1st bar after 8:30 AM and use this to calculate number of bars ago and use this as the start point of your line.
                  RayNinjaTrader Customer Service

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by bortz, 11-06-2023, 08:04 AM
                  47 responses
                  1,611 views
                  0 likes
                  Last Post aligator  
                  Started by jaybedreamin, Today, 05:56 PM
                  0 responses
                  9 views
                  0 likes
                  Last Post jaybedreamin  
                  Started by DJ888, 04-16-2024, 06:09 PM
                  6 responses
                  19 views
                  0 likes
                  Last Post DJ888
                  by DJ888
                   
                  Started by Jon17, Today, 04:33 PM
                  0 responses
                  6 views
                  0 likes
                  Last Post Jon17
                  by Jon17
                   
                  Started by Javierw.ok, Today, 04:12 PM
                  0 responses
                  22 views
                  0 likes
                  Last Post Javierw.ok  
                  Working...
                  X