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

Clear Method Indicator

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

    Clear Method Indicator

    Does anyone have an indicator for Ron Black's Clear Method (Swing Detector) from the "Technical Analysis of Stocks & Comodities" magazine, September 2010 Issue that works on NJ7?

    #2
    Stockjock,

    I found it. Please find it attached.

    Traders' Tips, a collection of code provided by developers to help implement trading ideas and techniques presented in the pages of Technical Analysis of Stocks & Commodities Magazine.
    Attached Files
    Adam P.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_AdamP View Post
      I found it. Please find it attached.
      Thanks very much. Can this be made into an ATM Strategy?

      Comment


        #4
        StockJock,

        You could probably find a way to make it work in an automated strategy, but an ATM strategy does not accept input from indicators.
        Adam P.NinjaTrader Customer Service

        Comment


          #5
          Originally posted by NinjaTrader_AdamP View Post
          You could probably find a way to make it work in an automated strategy, but an ATM strategy does not accept input from indicators.
          I'm just learning NJ7 programming language. So there's a differrence between Automated Strategy and ATM Strategy? Do both NJ's indicators and strategies use the C# language, so that I can just do some editing on the Clear Method indicator and make it into a strategy?

          Comment


            #6
            StockJock,

            Indicators and strategies have different namespaces they belong to so the two aren't totally interchangeable. They both use C# however, and you can call indicators in a strategy generally.

            An ATM strategy is for managing orders (even manually placed orders), but can also be used in an automated strategy to manage orders it places. ATM strategies automatically manage stops, targets, break-evens, etc.

            We have a strategy webinar you could attend that covers how to use the Strategy Wizard. The Strategy Wizard would require no programming to setup strategies, however some things are not possible with the Strategy Wizard vs. code.

            Schedule of webinars : http://www.ninjatrader.com/webinars

            If you are interested in learning to code NinjaScript, here is a good introductory video.

            Download NinjaTrader FREE at http://www.ninjatrader.comThis video is a NinjaScript tutorial on creating a strategy based on overbought/oversold conditions of...


            Also, our support forum has reference samples on how to code certain things.

            Adam P.NinjaTrader Customer Service

            Comment


              #7
              When I try to import the indicator I get an error, but I don't know which file its referring to. I don't think its the one you just gave me.
              You have custom NinjaScrip files on your PC that have programming errors. These errors must be resolved before you can import a NinjaScript Archive File.
              Is there an easy way to locate the file with the error?

              Comment


                #8
                StockJock,

                Please follow the instructions below to see where the errors are coming from after compiling only one indicator. This will allow you to debug the offending indicator/strategy or remove it from your PC. If you are wondering why you receive an error when compiling only one indicator, it is because NinjaTrader compiles all indicators and strategies- not just one.

                Open NinjaTrader
                • From the Control Center select the Tools menu--> select the Edit NinjaScript menu item--> select Indicator
                • Select an indicator and double click on it.
                • A new window will appear and you will need to right click in the window and select Compile to compile the indicators.
                • At the bottom of the window a new section will appear where you can find the error locations.
                • From there you have the option to remove the indicator or debug it.


                If you are unsure as to what the error is indicating, please send me a screenshot of the error with the name and description fields clearly readable.

                To send a screenshot press Alt + PRINT SCREEN to take a screen shot of the selected window. Then go to Start--> Accessories--> Paint, and press CRTL + V to paste the image. Lastly, save as a jpeg file and send the file as an attachment.
                Adam P.NinjaTrader Customer Service

                Comment


                  #9
                  So I'll need to go through the entire list of indicators and check each one if it doesn't compile correctly?

                  Comment


                    #10
                    StockJock,

                    No, you would only need to do this on one indicator. It will show any issues with any other indicator or strategy since they all get compiled at the same time.
                    Adam P.NinjaTrader Customer Service

                    Comment


                      #11
                      Were you able to resolve your issue StockJock?
                      BertrandNinjaTrader Customer Service

                      Comment


                        #12
                        Hi

                        i'm trying to call this indicator for a really easy strategy.
                        sell if the ShortTermSwings goes down, target 40 ticks

                        here the code:

                        // Selling condition
                        if (ShortTermSwings().Trend[0] < ShortTermSwings().Trend[1])
                        {
                        EnterShort(DefaultQuantity,
                        "Vente");
                        SetProfitTarget(
                        "Vente", CalculationMode.Ticks, 42*TickSize);
                        }

                        but i don't understand why after hitting 42 ticks, the indicator continue to go down and the script is not taking a new position (as shown on the picture below).

                        I think that i have to call the line of the indicator but i don't now the code to call it.

                        Can you help ?
                        Attached Files

                        Comment


                          #13
                          Thomas,

                          Please read the following :

                          Adam P.NinjaTrader Customer Service

                          Comment


                            #14
                            Originally posted by Thomas79 View Post
                            // Selling condition
                            if (ShortTermSwings().Trend[0] < ShortTermSwings().Trend[1])
                            {
                            EnterShort(DefaultQuantity,
                            "Vente");
                            SetProfitTarget(
                            "Vente", CalculationMode.Ticks, 42*TickSize);
                            }
                            Thomas79,

                            Interesting code. What indicator are you referencing with ShortTermSwings()?

                            Comment


                              #15
                              Hi StockJock

                              this is the indicator of Ron Black's Clear Method from the "Technical Analysis of Stocks & Comodities" magazine, September 2010, the one than you talk on your first message...

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Belfortbucks, Today, 09:29 PM
                              0 responses
                              2 views
                              0 likes
                              Last Post Belfortbucks  
                              Started by zstheorist, Today, 07:52 PM
                              0 responses
                              7 views
                              0 likes
                              Last Post zstheorist  
                              Started by pmachiraju, 11-01-2023, 04:46 AM
                              8 responses
                              150 views
                              0 likes
                              Last Post rehmans
                              by rehmans
                               
                              Started by mattbsea, Today, 05:44 PM
                              0 responses
                              6 views
                              0 likes
                              Last Post mattbsea  
                              Started by RideMe, 04-07-2024, 04:54 PM
                              6 responses
                              33 views
                              0 likes
                              Last Post RideMe
                              by RideMe
                               
                              Working...
                              X