Draw lines from candle 12 hours ago

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #224807 quote
    Crillezz
    Participant
    Veteran

    Hey everyone! I’ve tried to make an indicator but can’t do it.

    I don’t think it’s a big problem for those of you who are talented.

    I am looking for an indicator that draws lines from high and low 12 hours ago.

    I am working with 60 minute chart, but would be great if it would work on other timeframes to.

    Then the lines should disappear after 24 hours.

    Here is an example.

    Thx

    gggggg.png gggggg.png
    #224809 quote
    Crillezz
    Participant
    Veteran

    Realized now that it doesn’t work as there will be so many lines.
    It´s better to mark one area between 11-13 hours earlier like this.

    hhhhhh.png hhhhhh.png
    #224817 quote
    robertogozzi
    Moderator
    Master

    There you go:

    DEFPARAM DrawOnLastBarOnly = true
    DrawRectangle(BarIndex[13],0,BarIndex[11],99999) coloured("Cyan",80) bordercolor("Blue",255)
    RETURN
    Crillezz thanked this post
    #224824 quote
    Crillezz
    Participant
    Veteran

    That was fast. Just what I wanted.

    Thanks 🙂

    #224825 quote
    Crillezz
    Participant
    Veteran

    Is it possible to draw a line also on the candle 12 hour back. High/low?

    I´m understand that there will be new lines every hour.

    ttttttt.png ttttttt.png
    #224845 quote
    robertogozzi
    Moderator
    Master

    Yes:

    DEFPARAM DrawOnLastBarOnly = true
    DrawVline(BarIndex[12]) coloured("Blue",255)
    RETURN
    Crillezz thanked this post
    #224846 quote
    Crillezz
    Participant
    Veteran

    Then I get a vertical line. Tried to switch to horizontal without success

    kkkkkkkkkkkkkkkkkk.png kkkkkkkkkkkkkkkkkk.png
    #224850 quote
    robertogozzi
    Moderator
    Master

    Where does the line should start and end?

    #224870 quote
    Crillezz
    Participant
    Veteran

    The lines should start on the candle 12 hours ago.
    And ends after a new 1h candle is close. And repeat the same procedure after every hour (1 hour timeframe).
    Draw new lines every hour on the high/low of the candle 12 hours ago.

    Hope you understand what I mean

    qqqqqqqqqqqqqq.png qqqqqqqqqqqqqq.png wwwww.png wwwww.png
    #224895 quote
    robertogozzi
    Moderator
    Master

    There it is:

    DEFPARAM DrawOnLastBarOnly = true
    DrawSegment(BarIndex[12],close[12],BarIndex,close[12]) coloured("Blue",255)
    RETURN
    Crillezz thanked this post
Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.

Draw lines from candle 12 hours ago


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
Crillezz @crillezz Participant
Summary

This topic contains 9 replies,
has 2 voices, and was last updated by robertogozzi
2 years, 3 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 12/04/2023
Status: Active
Attachments: 6 files
Logo Logo
Loading...