last low/ last high

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #214849 quote
    thebaron
    Participant
    Average

    hello

    i m looking for an indicator showing me the last high and low from an upper time frame

    for or example in a 1 mn timeframe chart to have a line for the last previous 30 mn high and low until the next 30 mn change . for 1 mn bar between 9 am and 9:30 am having a line coresponding at high and low of 8:30am- 9 am
    if i want 30 mn high low, but to have the possibility to select different time frame inside the indicator

    in advance thanks

    #214852 quote
    JS
    Participant
    Senior

    Hi @thebaron

    You can try this…

     

    DefParam DrawOnLastBarOnly=True
    TimeFrame(30 minute, UpdateOnClose)
    xHigh1=High[1]
    xLow1=Low[1]
    
    TimeFrame(1 minute)
    DrawHLine(xHigh1)Coloured("Red")
    DrawText("#xHigh1#",BarIndex+10,xHigh1+2*pipsize)Coloured("Red")
    DrawHLine(xLow1)Coloured("Green")
    DrawText("#xLow1#",BarIndex+10,xLow1+2*pipsize)Coloured("Green")
    
    Return
    #214858 quote
    thebaron
    Participant
    Average

    thks but it did not work ?

    #214859 quote
    JS
    Participant
    Senior

    Hi @thebaron

    Did you add the indicator to the “price”…?

    What was the time frame of your open chart…?

    #214860 quote
    thebaron
    Participant
    Average
    yes on esxxx 1 mn
    #214863 quote
    JS
    Participant
    Senior

    Hi @thebaron

    Strange… It works for me…

    What market is “esxxx”…?

    #214864 quote
    thebaron
    Participant
    Average
    futur sp500
    #214865 quote
    JS
    Participant
    Senior

    Here’s what I see on the SP500…

    What version of ProRealTime are you using…?

    #214870 quote
    thebaron
    Participant
    Average
    pro 11 but the value on your chart are the same between 18h-22h, i want the previous half hour high/low on 1 mn chart “or 1 mn bar between 9 am and 9:30 am having a line coresponding at high and low of 8:30am- 9 am”
    #214871 quote
    JS
    Participant
    Senior

    The indicator can be improved but does it work for you now…?

    Do you see the lines and the text…?

    #214872 quote
    thebaron
    Participant
    Average
    when i test yesterday i did not increase the view, i have it on the chart
    #214877 quote
    JS
    Participant
    Senior
    Hi @thebaron

    Here is the adjusted indicator…

    (You can adjust the time frames)    

    DefParam DrawOnLastBarOnly=True
    TimeFrame(30 minute, UpdateOnClose)
    HTF=GetTimeFrame
    xHigh1=High
    xLow1=Low
    
    TimeFrame(1 minute)
    LTF=GetTimeFrame
    Period=HTF/LTF
    
    For i=0 to Period-1
    If High[i]=xHigh1 then
    x1=BarIndex[i]
    EndIf
    Next
    
    DrawSegment(x1,xHigh1,BarIndex-3,xHigh1)Coloured("Red")
    DrawText("#xHigh1#",BarIndex+1,xHigh1,SansSerif,Bold,16)Coloured("Red")
    
    For i=0 to Period-1
    If Low[i]=xLow1 then
    x2=BarIndex[i]
    EndIf
    Next
    
    DrawSegment(x2,xLow1,BarIndex-3,xLow1)Coloured("Green")
    DrawText("#xLow1#",BarIndex+1,xLow1,SansSerif,Bold,16)Coloured("Green")
    
    Return

    #214880 quote
    thebaron
    Participant
    Average
    at the start i have h an l l and after no more h line  and look at the start its 12h11 and not 12h
    #214883 quote
    JS
    Participant
    Senior
    The line(s) start at the “High” or “Low” of the previous period (30 min)…
Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.

last low/ last high


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
thebaron @thebaron Participant
Summary

This topic contains 13 replies,
has 2 voices, and was last updated by JS
2 years, 8 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 05/17/2023
Status: Active
Attachments: 4 files
Logo Logo
Loading...