Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Find all candles that closed at least 90% on top

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

    Find all candles that closed at least 90% on top

    I would like Ninjatrader to find candles that closed 90% from it top ( so very little or no shadows/ wicks) if that is true color it blue

    please advise how to do this.

    #2
    Hi wallsteetking,

    This is possible with custom programming in NinjaScript. Do you have the calculation or are looking for help building it? This one could be used to compare High to Close and color if smaller than 10% change.

    if ((High[0] - Close[0]) / High[0] <= .1)
    BarColor = Color.Blue;
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Hey Ryan i been trying to make this code work however, when i run the stratgy it highlights all of the bars.. could there be something wrong with the code.

      Comment


        #4
        Would you see the same outcome with this changed snippet below?

        double perc = (High[0] - Close[0]) / High[0];

        if (perc >= 0.001)
        BarColor = Color.Blue;
        BertrandNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by ETFVoyageur, Today, 04:00 PM
        0 responses
        5 views
        0 likes
        Last Post ETFVoyageur  
        Started by AaronKTradingForum, Today, 03:44 PM
        1 response
        6 views
        0 likes
        Last Post AaronKTradingForum  
        Started by Felix Reichert, 04-26-2024, 02:12 PM
        11 responses
        77 views
        0 likes
        Last Post Felix Reichert  
        Started by junkone, 04-28-2024, 02:19 PM
        7 responses
        82 views
        1 like
        Last Post junkone
        by junkone
         
        Started by pechtri, 06-22-2023, 02:31 AM
        11 responses
        136 views
        0 likes
        Last Post Nyman
        by Nyman
         
        Working...
        X