Looking for the ATR indicator

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #167700 quote
    thomas2004chthomas2004ch
    Participant
    Senior

    Hi,

    There is the ATR indicator but it just take CLOSE as the parameter. I wonder if there is ATR which take HIGH, LOW and CLOSE as input?

    #167709 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    The built-in Atr DOES allow to select the data source parameter (see pic).

    In any case, this a custom version you can tailor to your needs by selecting the data source with the indicator properties (it’s the same as PRT’s):

    src  = customclose
    p    = 14
    MyTR = max(Range,max(abs(high - src[1]),abs(low - src[1])))
    IF BarIndex < p THEN
       MyATR = MyTR
    ELSE
       MyATR = ((MyATR[1] * (p - 1)) + MyTR) / p
    ENDIF
    RETURN MyATR
    ATR-4.jpg ATR-4.jpg
    #167728 quote
    thomas2004chthomas2004ch
    Participant
    Senior

    Fine, thanks!

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

Looking for the ATR indicator


ProBuilder: Indicators & Custom Tools

New Reply
Author
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by thomas2004chthomas2004ch
5 years, 5 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 04/21/2021
Status: Active
Attachments: 1 files
ProRealCode ProRealCode
Loading...