Is it possible to have the same indicator on worden tc2000
It displays the highest and lowest annual, quarterly, monthly and weekly candlestick by a horizontal white line
thank you in advance
Very cordial
once start=0
once currentyearhigh=undefined
once currentyearlow=undefined
once currentquarterhigh=undefined
once currentquarterlow=undefined
once currentmonthhigh=undefined
once currentmonthlow=undefined
once currentweekhigh=undefined
once currentweeklow=undefined
if (year =2001 and year[1] < 2018) or (year=2018 and barindex=0) then
currentyearhigh=high
currentyearlow=low
currentquarterhigh=high
currentquarterlow=low
currentmonthhigh=high
currentmonthlow=low
currentweekhigh=high
currentweeklow=low
start=1
endif
if start and start[1] and opendayofweek < opendayofweek[1] then
DRAWHLINE(currentweekhigh)
DRAWHLINE(currentweeklow)
currentweekhigh=high
currentweeklow=low
endif
if start and start[1] and openmonth <> openmonth[1] then
DRAWHLINE(currentmonthhigh)
DRAWHLINE(currentmonthlow)
currentmonthhigh=high
currentmonthlow=low
endif
if start and start[1] and openmonth <> openmonth[1] and openmonth mod 3 =0 then
DRAWHLINE(currentquarterhigh)
DRAWHLINE(currentquarterlow)
currentquarterhigh=high
currentquarterlow=low
endif
if start and start[1] and openyear <> openyear[1] then
DRAWHLINE(currentyearhigh)
DRAWHLINE(currentyearlow)
currentyearhigh=high
currentyearlow=low
endif
if start=1 then
currentyearhigh=max(high,currentyearhigh)
currentyearlow=min(low,currentyearlow)
currentquarterhigh=max(high,currentquarterhigh)
currentquarterlow=min(low,currentquarterlow)
currentmonthhigh=max(high,currentmonthhigh)
currentmonthlow=min(low,currentmonthlow)
currentweekhigh=max(high,currentweekhigh)
currentweeklow=min(low,currentweeklow)
endif
return
|