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

Leader MACD Red Line?

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

    Leader MACD Red Line?

    Hi there I am just looking at the Leader Macd indicator which incorporates a Red line as well as the usual 2 and I was wondering how I could include it in a strategy as I cant seem to find the the red line in the set build conditions of the strategy builder as it simply gives the basic MACD parameters. I am confused and have probably confused everyone reading this so sorry. Any help would be appreciated.

    Regards

    Bogan7

    #2
    If you use the Condition Builder you'll see it can show you what each line is named, or if you use the chart Data Box you can see it there as well.

    But if you want to use the leader line, it is:
    Code:
    LeaderOfMACD(12, 26, 9).Leader[0]
    HTH.

    Mike

    Comment


      #3
      Bogan7,

      In the Condition Builder, after you have selected your indicator you want to pay attention to the Parameters section on the bottom. You want to pay attention to the Plot parameter to change it to your Leader plot.
      Josh P.NinjaTrader Customer Service

      Comment


        #4
        Hi there thanks for all your help so far guys. What i would also like to do if its possible is once the red line crosses the zero I would like to place my order at 2 ticks above say the 8 ema line and this would move with the chart till about 5 bars then cancel if not filled is this possible?

        Comment


          #5
          Yes this is possible but very complex using the wizard, this is a task I would advise accomplishing using direct programming.
          RayNinjaTrader Customer Service

          Comment


            #6
            Originally posted by NinjaTrader_Ray View Post
            Yes this is possible but very complex using the wizard, this is a task I would advise accomplishing using direct programming.
            Thanks for the reply Ray

            Comment


              #7
              Originally posted by Bogan7 View Post
              Hi there thanks for all your help so far guys. What i would also like to do if its possible is once the red line crosses the zero I would like to place my order at 2 ticks above say the 8 ema line and this would move with the chart till about 5 bars then cancel if not filled is this possible?
              Bogan7, brief example:

              Code:
              if CrossAbove(LeaderOfMACD(12, 26, 9).Leader, 0, 1)
              
              EnterLongLimit(EMA(8) + 0.50, "my signal");
              GL.

              Comment


                #8
                And I'll add a bit more for you

                Code:
                if (Position.MarketPosition != MarketPosition.Flat)
                Useful to know where you stand. .Flat, .Long, .Short...

                You'll want to use that so you only enter once. As for resubmitting the order for 5 minutes, if the limit order isn't filled and the condition remains true on the next OnBarUpdate (based on your data interval period ie 1 minute) then it will re-submit it again.

                GL.

                Comment


                  #9
                  Thank you very much

                  Originally posted by ctrlbrk View Post
                  And I'll add a bit more for you

                  Code:
                  if (Position.MarketPosition != MarketPosition.Flat)
                  Useful to know where you stand. .Flat, .Long, .Short...

                  You'll want to use that so you only enter once. As for resubmitting the order for 5 minutes, if the limit order isn't filled and the condition remains true on the next OnBarUpdate (based on your data interval period ie 1 minute) then it will re-submit it again.

                  GL.

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by lightsun47, Today, 03:51 PM
                  0 responses
                  4 views
                  0 likes
                  Last Post lightsun47  
                  Started by 00nevest, Today, 02:27 PM
                  1 response
                  8 views
                  0 likes
                  Last Post 00nevest  
                  Started by futtrader, 04-21-2024, 01:50 AM
                  4 responses
                  44 views
                  0 likes
                  Last Post futtrader  
                  Started by Option Whisperer, Today, 09:55 AM
                  1 response
                  13 views
                  0 likes
                  Last Post bltdavid  
                  Started by port119, Today, 02:43 PM
                  0 responses
                  9 views
                  0 likes
                  Last Post port119
                  by port119
                   
                  Working...
                  X