Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy, new indicator to be programmed

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

    Strategy, new indicator to be programmed

    Hello all,

    Here is my problem. It takes me hours to go though all the charts manually and look for my entry pattern. I would like to be able to have a custom indicator that detects my entry pattern , that way I could then run it in market analyzer and get a list of all potential stocks.

    I was wondering if any programmers out there familiar with ninjascript could help me out coding this indicator, I would really appreciate it ! Here is the logic for a buy: there must be at least 5 consecutives bars that closed above 10 ema, then 1 bar that closes below or really close to 10ema and the following bar that closes above 10 ema and above the close of the previous bar (the one that closed below 10 ema). If you need more information please pm me.

    Thank you
    Last edited by mlambole; 08-14-2010, 06:02 PM.

    #2
    Hello,

    Hopefully someone will help you. As an alternative you may want to go here:
    DenNinjaTrader Customer Service

    Comment


      #3
      mlambole, I have almost no background in programming or ninjascrpting. I just made my first 2 indicators using Help files & a forum post in the last 36 hours.

      Here is an indicator with all of your Entry criteria. My twist for "closes below or near 10 ema" was to simply look for a Close below a faster ema.
      The default setting for main (slow) EMA is 10, and faster EMA is 7. These are customizable.

      This indicator does NOT plot any EMA on the chart, it only draws Green or Red Triangles below/above your Long/Short entry bars.

      The code also contains Sound Alerts, but its the first time I have coded those, and have yet to test it in real-time.

      Having said that, I have NO clue as to how to set this up with Market Analyzer.

      [Made with NT 6.5. Not tested on NT 7.]
      Attached Files
      Last edited by ekshay; 08-17-2010, 05:06 PM.

      Comment


        #4
        Ekshay,

        Thank you so much for your help. It turns out I also looked at the documentation and was able to create the indicator I wanted.

        To run it through market analyzer, your script must return 1 for example when a certain condition is met and then you can load the indicator in market analyzer and tell him to go through all the stocks and keep the ones where your indicator returns 1.

        in the initialize function you add :
        Add(new Plot(Color.FromKnownColor(KnownColor.Orange), PlotStyle.Bar, "Plot0"));

        and in the onbarupdate function when the buy/sell condition is met you return 1 like this
        Plot0.Set(1);


        That's it

        Cheers !

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        595 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        343 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        103 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        556 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        554 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X