-1 for red bar on chart.
You will notice from attached images that the indicators does not plot correctly on many occasions on MC chart which makes me believe that there is some problem with Kagi charts. ( attached TS Chart for comparision)
Code: Select all
{ 1 if direction is up (green bar);
-1 if direction is down (red bar) }
variables:
Direction( 0 ) ;
if Close > High[1] or Close < Low[1] then
begin
if Close < Low[1] and Direction >= 0 then
begin
Direction = -1 ;
end
else if Close > High[1] and Direction <= 0 then
begin
Direction = 1 ;
end ;
end ;
Plot1( Direction, "Direction" ) ;