Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Three Line Stochastics

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

    Three Line Stochastics

    I am brand new to NT, and would characterize myself as a novice with scripts and indicator programming. My request is for someone well versed in this arena, to explain in layman's terms how to create a new stochastics indicator with an additional line or period. I am including an example of what I am looking for.

    Parameters:
    • Overall Period (14) - the number of periods used to determine the highest high and lowest low.
    • %K MA Period (3) - the number of periods used to determine the moving average for the %K value.
    • %D MA Period (3) - the number of periods used to determine the moving average for the %D value.
    • AdditionalLinePeriod (3) - the number of periods used to determine an additional Moving Average on the Stochastic."

    These parameters can go up to 999 for each line and they plot three different visible lines on the graphs.

    I was able to use this indicator when I was using Futuresource, way back when.

    I am not sure if this has been requested before for NT 7, so a link may well suffice. Any help would be greatly appreciated.

    Thanks!

    #2
    Hello Gmicc,

    Welcome to the NinjaTrader forums!

    This is pretty close to the standard stochastic indicator so you can work from that if you want to develop your own script. Edit the standard stochastic indicator then Right Click > Save as to make a copy of it. You can add an additional plot here if you like. Please see here for an introductory guide to indicator development in NinjaTrader.

    You can also do this with no custom programming. Apply stochastics to the chart and then add an SMA to it. You can select other indicators as your input series when you apply the SMA. Please see here for help working with indicators.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Ryan,

      Adding an SMA does not do it. I tried Ninjascript and am lost? As I mentioned, I know nothing of programming and NTscript is not easy even though I followed along as best as I could.

      Maybe it is just easier to edit the regular stochastic indicator? Although, looking at that and comparing with NTscript are two totally different animals, even more confusing.

      Attached is a Word document with the formula for what I am trying to implement. Also attached is what NTscript produced and I tried to implement. Where I went wrong and what comes next I don't know? Perhaps you can tell me what to do from here?
      Attached Files

      Comment


        #4
        To Edit the indicator, click Tools > Edit NinjaScript > and open the stochastics indicator. Right click > Save as to provide a new name.

        There can definitely be a learning curve to NinjaScript, so it may be best to start with the general tutorials so you can get a feel for the structure and where things go. If you want to get this coded right away, your best option is a NinjaScript consultant. These are 3rd party NinjaTrader partners who can write code to your specifications. A list of NinjaScripts consultants is available here:

        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          This is frustrating! I read your tutorials and followed along but all I get is errors where I am supposed to input things? Your tutorials don't tell me what I did wrong or what should be inputted properly or how to correct them? Any help would be appreciated from anyone who is familiar with programming this stuff!

          Comment


            #6
            I'm sorry you're frustrated. You may want to take a step back from working with code and start with our strategy wizard. This is a point and click interface you can use to setup trade conditions and actions. You can then view the resulting code generated with no programming experience required. See here for getting started working with the condition builder.


            This will allow you to work in an environment without coding errors. Once you are comfortable with the strategy wizard, try the tutorials again.

            You can delete any files you've created so far through Tools > Edit NinjaScript > Indicator. Click on a file and select delete.
            Ryan M.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by kevinenergy, 02-17-2023, 12:42 PM
            118 responses
            2,778 views
            1 like
            Last Post kevinenergy  
            Started by briansaul, Today, 05:31 AM
            0 responses
            7 views
            0 likes
            Last Post briansaul  
            Started by fwendolynlpxz, Today, 05:19 AM
            0 responses
            4 views
            0 likes
            Last Post fwendolynlpxz  
            Started by traderqz, Yesterday, 12:06 AM
            11 responses
            28 views
            0 likes
            Last Post NinjaTrader_Gaby  
            Started by PaulMohn, Today, 03:49 AM
            0 responses
            8 views
            0 likes
            Last Post PaulMohn  
            Working...
            X