Bei dieser Version können Sie auch die Woche auswählen. Wenn Sie Woche nicht auswählen, wird Tag verwendet.
Wenn Sie sowohl „Gestern“ als auch „Heute“ auswählen, wird „Heute“ ignoriert.
defparam drawonlastbaronly=true
IF Gestern AND Heute THEN
Heute = 0
ENDIF
Rh = 34
Gh = 139
Bh = 34
//LowColours
Rl = 255
Gl = 0
Bl = 0
//********************************************************************************************************************************************************************
IF Woche THEN
// Woche
IF OpenDayOfWeek < OpenDayOfWeek[1] THEN
HighYesterDay = HighToDay
LowYesterDay = LowToDay
CloseYesterday= close[1]
EQYesterday = (HighYesterDay + LowYesterDay) / 2
HighToDay = high
LowToDay = low
ELSE
HighToDay = max(high,HighToDay)
LowToDay = min(low, LowToDay)
ENDIF
If Gestern Then
DrawSegment(Barindex-1,HighYesterDay,Barindex+10,HighYesterDay)Coloured(rh,gh,bh)Style(Line,2)
DrawSegment(Barindex-1,LowYesterDay,Barindex+10,LowYesterDay)Coloured(rl,gl,bl)Style(Line,2)
DrawSegment(Barindex-1,CloseYesterDay,Barindex+10,CloseYesterDay)Coloured(30,144,255)Style(Line,2)
DrawSegment(Barindex-1,EQYesterDay,Barindex+10,EQYesterDay)Coloured(30,144,255)Style(dottedLine,2)
EndIf
If heute Then
DrawSegment(Barindex,HighToDay,Barindex++10,HighToDay)Coloured(rh,gh,bh)Style(Line,2)
DrawSegment(Barindex,LowToDay,Barindex++10,LowToDay)Coloured(rl,gl,bl)Style(Line,2)
EndIf
ELSE
// Tag
HighYesterDay = DHigh(1)
LowYesterDay = DLow(1)
CloseYesterday= DClose(1)
EQYesterday = (DHigh(1)+DLow(1))/2
HighToDay = DHigh(0)
LowToDay = DLow(0)
If Gestern Then
DrawSegment(Barindex-1,HighYesterDay,Barindex+10,HighYesterDay)Coloured(rh,gh,bh)Style(Line,2)
DrawSegment(Barindex-1,LowYesterDay,Barindex+10,LowYesterDay)Coloured(rl,gl,bl)Style(Line,2)
DrawSegment(Barindex-1,CloseYesterDay,Barindex+10,CloseYesterDay)Coloured(30,144,255)Style(Line,2)
DrawSegment(Barindex-1,EQYesterDay,Barindex+10,EQYesterDay)Coloured(30,144,255)Style(dottedLine,2)
EndIf
If heute Then
DrawSegment(Barindex,HighToDay,Barindex++10,HighToDay)Coloured(rh,gh,bh)Style(Line,2)
DrawSegment(Barindex,LowToDay,Barindex++10,LowToDay)Coloured(rl,gl,bl)Style(Line,2)
EndIf
ENDIF
//********************************************************************************************************************************************************************
Return