Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Custom indicator

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

    Custom indicator

    I wish to create a simple indicator? Can anyone help me?
    The coditions is this:
    two types of alerts

    1. the close is less than open and the high is equal to highest high of the last 5 bars and the high is above ema(21)
    2. the close is more than open and low is equal to lowest low of the last 5 bars and the low is below ema(21)

    Is it posbbiel to write indicator that give me this alert?

    #2
    Hello vbstyle2,

    Thanks for your post.

    Yes, you can create multiple conditions, and as the action issue an alert.

    For the Alert you would use thee Alert() method: https://ninjatrader.com/support/help...nt8/?alert.htm
    For determining Close is less than open Close[0] < Open[0]
    For determining if the High[0] is equal to the Highest high of the previous 5 bars you would use the MAX() indicator with the High data series as the input, for example: If (High[0] == MAX(High, 5)[1]). Reference: https://ninjatrader.com/support/help...aximum_max.htm
    For determining if above the EMA it would be High[0] > EMA(21)[0]
    For determining Close is greater than the open would be Close[0] > Open[0]
    For determining low is equal to lowest low of the last 5 bars you would use the MIN() indicator with the lOw data series as the input, for example if (Low[0] == M IN(Low, 5)[1]), Reference: https://ninjatrader.com/support/help...inimum_min.htm
    For determining if below the EMA, it would be Low[0] < EMA(21)[0].

    If you are not familiar with Ninjascript it may be difficult but here is a resource you can start with: https://www.youtube.com/watch?v=BA0W...uWXkWe0Nf&t=19


    If you eventually plan to use this as a strategy you might just want to create this in the strategy builder as you would be easily able to create these conditions and the alert actions.
    Here are the educational resource available on the strategy builder:
    Free live webinar every other Thursday at 4:00 PM EST, through this link to all webinars: https://ninjatrader.com/PlatformTraining
    Previous recording of the Strategy Builder 301 webinar: https://youtu.be/HCyt90GAs9k?list=PL...auWXkWe0Nf&t=2
    Help guide for the strategy builder: https://ninjatrader.com/support/help...gy_builder.htm
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Is it possible you can write one up for me? I would like those conditions alert to combo with the tick counter enhanced thing.

      Comment


        #4
        Hello vbstyle2,

        Thanks for your reply.

        Sorry, we do not provide code writing services.

        If you would like something created for you, we can provide a link to 3rd party programmers in the NinjaTrader ecosystem.

        Paul H.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by GLFX005, Today, 03:23 AM
        0 responses
        1 view
        0 likes
        Last Post GLFX005
        by GLFX005
         
        Started by XXtrader, Yesterday, 11:30 PM
        2 responses
        11 views
        0 likes
        Last Post XXtrader  
        Started by Waxavi, Today, 02:10 AM
        0 responses
        6 views
        0 likes
        Last Post Waxavi
        by Waxavi
         
        Started by TradeForge, Today, 02:09 AM
        0 responses
        11 views
        0 likes
        Last Post TradeForge  
        Started by Waxavi, Today, 02:00 AM
        0 responses
        2 views
        0 likes
        Last Post Waxavi
        by Waxavi
         
        Working...
        X