Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Trend from one point to another

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

    Trend from one point to another

    Is there an easy way (beside programming a loop) to check if a value has trended only down from a given point? I don't need nbarnsdown/up because the numbers of bars can vary.

    Example: I want to know if a stochastic has only traveled down when it hits 20 and started at 80. I just need to know which bar 80 started at.

    Maybe the better question is how can I find out which bar a value was reached or exceeded.

    Regards/Danke

    Cliff

    #2
    You can try using the CrossAbove or CrossBelow condition along with MRO.



    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Josh

      Thanks for the reply. That will give me the bar when the value was reached or exeeded. Got it.

      And this use this value for nbarsup/down to verify there were no opposite trending bars in the period?

      Comment


        #4
        That will give you the bar that it got to your threshold value and then you will have to run some logic to come back and test if there were any counter trending bars. Only way I can think of to do this check is with a loop though. You will get the bar # of the threshold. Just use a counter that goes from 0 up to that bar # and check all those bars for a counter trend. If a counter trend happens then stop the loop and stop the trade I suppose.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Got it. Thanks.

          Comment


            #6
            Dog food, MRO will NOT work on multi-time frame strategies. Mine is.

            Comment


              #7
              Then you might need to resort to loops.
              Josh P.NinjaTrader Customer Service

              Comment


                #8
                Thanks, doing it now.

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                647 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                369 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                108 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                572 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                573 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X