Stefan, I fiddled with this for a while and came to the conclusion that any indicator that increments daily insists on being drawn as a continuous line rather than as horizontal segments or steps. Here's my misguided effort; but it only creates step levels if the values are sustained for more than one day.
{for price above yesterdays 3EMA} S1:=ValueWhen(1,Ref(Mov(C,3,E),-1)<C,Ref(Mov(C,3,E),-1)); {for price below yesterdays 3EMA} R1:=ValueWhen(1,Ref(Mov(C,3,E),-1)>C,Ref(Mov(C,3,E),-1)); R1; S1;
My conclusion: Best thing to do is use the color/style setting on the standard shifted MA and specify a dotted line style (the last choice) typically used to represent SAR levels. You can increase the weight a notch or two and it seems to do the job without all the gymnastics. For the heck of it try plotting R1 and S1 as separate indicators and colors and see whadya think. Not really true to the articles intent, but mildly interesting results.
Craig |