While not exactly what you are looking for, there is an indicator called the 'Directional Day Filter' which is quite useful for determining the trend for the day based on the first hour.
I could provide two different versions coded in C# (NinjaScript) and here is the EasyLanguage code if it helps:
Quote:
Inputs: PlotTime(5),Delay(60) ;
Vars: NuHi(c), NuLo(c), Med(0);
If d<>d[1] then begin
NuHi = H;
NuLo = L;
end;
If H>NuHi then NuHi = H;
If L<NuLo then NuLo = L;
If T = CalcTime(Sess1StartTime,PlotTime) then Med = (NuHi+NuLo)/2;
If Med > 0 then plot1(Med,"DDFLine");
If t = CalcTime(Sess1StartTime,Delay) and nulo>0 then begin
Plot2(NuHi,"hi");
Plot3(NuLo,"lo");
Plot4(C,"C");
If checkalert then alert = true;
end;
|