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

ADX slope issue

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

    ADX slope issue

    I want to enter a long the first bar after the ADX slopes up, not every time the ADX slopes up though. when the ADX resets and slopes down then I can reenter after another slope up of the ADX. Also, when I enter, the trade must go 5 pts and then the ADX must reset before I enter a trade in the same direction. Anyone know how to do this? Thanks

    #2
    Hello,

    Thank you for your forum post.

    Are you coding this manually or are you using the strategy wizard?

    I look forward to assisting you further.

    Comment


      #3
      I m using the strategy wizard. Is this the best way to do it?

      Comment


        #4
        Hello,

        It only pertains to what your programming level is.

        If you have no programming experience the strategy wizard is a good place to start.


        You will want to use the rising() functions. Add Rising to the left side of the condition builder and then change the parameter to be the ADX. Then on the right side of the condition builder add Misc->True and in the middle use the == sign. To express this condition.

        I belive you have got this far thus far, but what you will want to add now is to use a varaible in this same set with the EnterLong(). Then set this variable to 0 for example. As part of your checking for entry condition the entry must also have this variable == 0. Then set this variable to 1 when you EnterLong(), then using Falling and once the falling condition has completed then set this variable back to 0 to allow the rising condition to trigger a trade again.

        Let me know if I can be of further assistance.

        Comment


          #5
          Hi,
          Thanks for your help, I'm still not exactly clear on this. I take longs when the DI plus is above the DI minus and when I get ADX slope and shorts when the DI minus is above the DI plus and I get ADX slope. For the short part in Do The Following i put EnterShort((int)(Variable0),"") and in the when the following conditions are true box I put Variable0==0. I have this all in set 1, how many sets do I need? How do I start another set after one is completed? Maybe you could dumb it down for me a little, Thank You!!

          Comment


            #6
            You cannot do that all in Set 1. To start another Set just switch to a different Set tab up on the top. Each set is evaluated in sequential order from Set 1 to Set 2 to 3 and so on and so forth.

            Also, you should not be putting Variable0 into your EnterLong(). That would mean you are trading that quantity which does not make sense. Variable0 is just to help you determine if you will trade or not trade.
            Josh P.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by benmarkal, Yesterday, 12:52 PM
            3 responses
            22 views
            0 likes
            Last Post NinjaTrader_Gaby  
            Started by helpwanted, Today, 03:06 AM
            1 response
            18 views
            0 likes
            Last Post sarafuenonly123  
            Started by Brevo, Today, 01:45 AM
            0 responses
            11 views
            0 likes
            Last Post Brevo
            by Brevo
             
            Started by aussugardefender, Today, 01:07 AM
            0 responses
            6 views
            0 likes
            Last Post aussugardefender  
            Started by pvincent, 06-23-2022, 12:53 PM
            14 responses
            244 views
            0 likes
            Last Post Nyman
            by Nyman
             
            Working...
            X