cci 100

bozmel

New Member
#1
help me, i want to add buy signal cross 100
here is the code

Code:
_SECTION_BEGIN("Background_Setting");
SetChartBkGradientFill( ParamColor("BgTop", colorBlack),
ParamColor("BgBottom", colorDarkGrey),ParamColor("TitleBack",colorGrey40));
SetChartBkColor(ParamColor("Outer Panel",colorPaleBlue));
SetChartOptions(0,chartShowArrows|chartShowDates);
_SECTION_END();

_SECTION_BEGIN("CCI cross zero");
pds = Param( "Periods", 20, 1, 200, 1 );
cc=CCI(pds);

BUY=Cross(cc,-0);
SELL=Cross(-200,cc);

col=IIf(BUY,colorBrightGreen,colorRed);


PlotShapes(IIf(Buy, shapeUpArrow, shapeNone),colorGreen);
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone),colorRed);

Plot( CC, "", col, styleLine,styleThick );
Plot(0,"",colorWhite,styleLine,styleThick);
Title =
EncodeColor(colorWhite)+ "CCI and Close price " + "\n " + Name() + " | " + EncodeColor(colorBrightGreen)
+ EncodeColor(colorBrightGreen) + "\n " + Date()
+"\n"+EncodeColor(colorWhite) +" Zero crossed CCI Cls Price ="+ IIf(BUY,C,IIf(SELL,C,Null)) ;
_SECTION_END();
 

Similar threads