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

Use indicator on Todays Date only.

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

    Use indicator on Todays Date only.

    How would I be able to Label Bars for Only the current Day? I'm not sure where to begin on doing something like this.
    For example if I want an indicator to display an up arrow on SMA crosses but for ONLY today.

    THanks!!!
    Last edited by r3n3v; 11-08-2018, 05:15 PM.

    #2
    Hello r3n3v,

    Thanks for your post.

    Can you provide further context on what you would like to do?

    Are you using daily bars or is this for intraday data?

    Do you want to show only the latest up arrow or all up arrows in intraday data of today?

    By "today" do you mean starting at midnight or starting at today's ETH session which began yesterday or perhaps today's RTH session?

    You may want to post a chart example to clarify.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      I mean today's RTH Session. I don't want to Display the indicator arrows for all sessions just for the current RTH Session. Thanks!

      Comment


        #4
        Hello r3n3v,

        Thanks for your reply.

        In the indicator, you can create a condition to check if the current bar is equal to the RTH start time and as the action, you can use RemoveDrawObjects() to remove all of the previously draw arrows. The indicator will continue drawing objects in the new RTH session.

        For example:

        if (ToTime(Time[0]) == ToTime(093000))
        {
        RemoveDrawObjects();
        }


        Reference: https://ninjatrader.com/support/help...rawobjects.htm

        Paul H.NinjaTrader Customer Service

        Comment


          #5
          Ok. Many thanks Paul. Will Try Thanks!!

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by jclose, Today, 09:37 PM
          0 responses
          6 views
          0 likes
          Last Post jclose
          by jclose
           
          Started by WeyldFalcon, 08-07-2020, 06:13 AM
          10 responses
          1,414 views
          0 likes
          Last Post Traderontheroad  
          Started by firefoxforum12, Today, 08:53 PM
          0 responses
          11 views
          0 likes
          Last Post firefoxforum12  
          Started by stafe, Today, 08:34 PM
          0 responses
          11 views
          0 likes
          Last Post stafe
          by stafe
           
          Started by sastrades, 01-31-2024, 10:19 PM
          11 responses
          169 views
          0 likes
          Last Post NinjaTrader_Manfred  
          Working...
          X