Lester, this is what you want and you can use it on any timeframe below the hourly too:
TimeFrameSet(inHourly); High60 = ValueWhen(DateNum() != Ref(DateNum(), -1), H); Low60 = ValueWhen(DateNum() != Ref(DateNum(), -1), L); Close60 = ValueWhen(DateNum() != Ref(DateNum(), -1), C); TimeFrameRestore(); High60x = TimeFrameExpand(High60, inHourly); Low60x = TimeFrameExpand(Low60, inHourly); Close60x = TimeFrameExpand(Close60, inHourly); Plot(IIf(TimeNum() >= 103000 AND TimeNum() <= 160500, High60x, Null), "", colorBlue, styleLine | styleThick); Plot(IIf(TimeNum() >= 103000 AND TimeNum() <= 160500, Low60x, Null), "", colorRed, styleLine | styleThick); Plot(IIf(TimeNum() >= 103000 AND TimeNum() <= 160500, Close60x, Null), "", colorYellow, styleLine | styleThick); Plot(Close, "", colorBlack, styleCandle); SetChartOptions(0, chartShowDates); --- In [email protected], "Lester Vanhoff" <[EMAIL PROTECTED]> wrote: > > I need the following code for intraday data (one-minute database): > > 1) HHV( High, between 09:30 and 10:30 ); > > 2) Close (at 10:30); > > Then I would need to plot those as horizontal lines each day from their start time till the end of the day. > > Tnx >
