15 Min High -Low Range on 1 Min chart

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #106452 quote
    TraderS
    Participant
    New

    Hi,

    I am not a programmer and looking for help to create an indicator to plot 15 minutes high-low range on a 1-minute chart.

    Please see the example in the attached image, I draw the line manually on a chart.

    Any help would be much appreciated.

    Screenshot-2019-09-04-at-10.25.46.png Screenshot-2019-09-04-at-10.25.46.png
    #106457 quote
    robertogozzi
    Moderator
    Master

    There you go:

    DEFPARAM CalculateOnLastBars=1000
    IF OpenMinute MOD 15 = 0 THEN
       HH = high
       LL = low
    ENDIF
    HH = max(HH,high)
    LL = min(LL,low)
    RETURN HH AS "High",LL AS "Low"
    ZeroCafeine thanked this post
    y-3.jpg y-3.jpg
    #106459 quote
    Vonasi
    Moderator
    Master
    #106465 quote
    Vonasi
    Moderator
    Master

    This adaptation of Roberto’s code is a little closer to what you drew.

    DEFPARAM CalculateOnLastBars=1000
    IF OpenMinute MOD 15 = 0 THEN
    DRAWSEGMENT(start,hh,barindex,hh)
    DRAWSEGMENT(start,ll,barindex,ll)
    start = barindex
    HH = high
    LL = low
    ENDIF
    HH = max(HH,high)
    LL = min(LL,low)
    RETURN
    Screenshot_1.png Screenshot_1.png
    #106472 quote
    TraderS
    Participant
    New

    Thank you so much Vonasi.

    #106481 quote
    GraHal
    Participant
    Master

    Link added to here

    Snippet Link Library

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

15 Min High -Low Range on 1 Min chart


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
TraderS @traders Participant
Summary

This topic contains 5 replies,
has 4 voices, and was last updated by GraHal
6 years, 5 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 09/04/2019
Status: Active
Attachments: 3 files
Logo Logo
Loading...