Dotted Swing Support Resistance



Dotted Swing Support Resistance
Dotted Swing Support Resistance


//www.aflcode.com

_SECTION_BEGIN("Price");
SetChartOptions(0,chartShowArrows|chartShowDates);
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
Plot( C, "Close", ParamColor("Color", colorDefault ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() ); 
_SECTION_END();

_SECTION_BEGIN("SWING SUPPORT RESISTANCE");

LB= Param("Look Back Periods",10,1,30,1);
R=ValueWhen(Cross(MA(C,LB),C),HHV(H,LB),1);
S=ValueWhen(Cross(C,MA(C,LB)),LLV(L,LB),1);
Color=IIf(O>C,colorBlack,colorBlue);
Plot (R,"Res",colorLime,8+16);
Plot (s,"Sup",colorRed,8+16);
Plot (C,"Close",color,64,32);

GraphXSpace=4;
_SECTION_END();

Previous
Next Post »