Saturday, July 18, 2009

RGR 3/10 Osc

[LegacyColorValue = true];
Inputs: Price(Close), Avg1(3), Avg2(10), Avg3(16), StdDsp(1), UpColor( DarkGreen), DnColor( DarkRed), ZeroColor( Red ); IF Currentbar>30 Then Begin IF StdDsp=1 Then Value1=Average(Price,Avg1)-Average(Price,Avg2); IF StdDsp<>1 Then Value1=Average((Price-(Average(Price,3)[3])), 2);
Value11 = value1;
Value2=Average(Value1,Avg3);
Plot1(Value1,"3/10Line"); Plot2(Value2,"16Line"); Plot3(0,"ZeroLine", DarkGray ); plot4(Value11,"3/10Line_2", DarkGray); { Color criteria }
if Value1 >= 0 then SetPlotColor(1,UpColor);if Value1 <= 0 then SetPlotColor(1,DnColor);
End;

No comments: