Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Red Green Red Trend Indicator

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

    Red Green Red Trend Indicator

    This is a good indicator which shows retracement in a trend . The attached is an tradestation format ELD file. I would really appreciate if someone can convert into a PAINT BAR indicator for NT7.

    [LegacyColorValue = true];
    {
    Notes: Paints bars based on the change of price from the lowest low or highest high
    of a given period with the addition of the Average True Range
    Input: BarLength - Number of bars to calculate lowest low or highest high (16 is the default value)
    ATRLength - Number of days to calculate the ATR and the SMA of the ATR

    This version is different from the base version in that there are no "neutral" bars. Any
    neutral bars are assumed to hold the direction/color of the prior bar.
    }
    Input: BarLength(16), ATRLength(9), ATRMultiple(2.5), pPlotWidth(1);
    Variables: SwingDirection(0);
    SwingDirection = LBRSwing2(BarLength,ATRLength,ATRMultiple);
    If CurrentBar > 1 Then Begin
    If SwingDirection = 1 then
    PlotPaintBar(High, Low, Open, Close, "LongShort", Green, Default, pPlotWidth);
    If SwingDirection = -1 then
    PlotPaintBar (High, Low, Open, Close, "LongShort", Red, Default, pPlotWidth);
    {Show ATR range on on Screen}
    Variable: ValueToPaint(0),Junk(False);
    ValueToPaint = AverageFC(AvgTrueRange(ATRLength), ATRLength) * ATRMultiple;
    Junk = DrawTextOnLastbar(-999999,0,NumToStr(ValueToPaint,2),Highest(High,3) + (3*TickValue),White,3);
    If CommentaryEnabled Then Begin
    CommentaryCL("The Value for switching colors is: ", ValueToPaint);
    End;
    End;

    #2
    Hi Ultrasound1,

    Thank you for your post and welcome to the forums!

    We have a comprehensive help guide that goes through the available NinjaScripts items and even some basic tutorials on creating your own script.

    * http://www.ninjatrader.com/support/helpGuides/nt7/index.html

    Our support forum is a wealth of knowledge from our user base and even includes some reference items on how to code particular items.

    * http://www.ninjatrader.com/support/forum/

    Additionally, we do have premium paid education course where you will spend 6-8 hours intensive courses designed to provide you with an in depth training on how to create, test and fully deploy automated strategues and indicators.

    * http://www.ninjatrader.com/PremiumEducation.php

    Lastly, you are always welcome to send in a support request on any items that you may need assistance with.

    Let me know if I can be of further assistance.
    Cal H.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    653 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    370 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    109 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    574 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    577 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X