Short Term System for Amibroker (AFL)
wangjia0427 about 15 years ago Amibroker (AFL)
short term trader.
Screenshots
Indicator / Formula
Copy & Paste Friendly
_SECTION_BEGIN( "Price" );
SetChartOptions( 0, chartShowDates | chartShowArrows | chartLogarithmic | chartWrapTitle );
Plot(C,"",colorBlack,styleCandle);
/*AdjBar = Param("Bar",0,0,BarCount,1);
"Index " + BI = GetBaseIndex(); //BI = BaseIndex String
FO = Ref(Foreign( BI,"O"),-AdjBar);
FH = Ref(Foreign( BI,"H"),-AdjBar);
FL = Ref(Foreign( BI,"L"),-AdjBar);
FC = Ref(Foreign( BI,"C"),-AdjBar);
PlotOHLC( FO,FH,FL,FC, BI, colorYellow);//Plot Sector Index.*/
if ( ParamToggle( "Tooltip shows", "All Values|Only Prices" ) )
{
ToolTip = StrFormat( "Open: %g\nHigh: %g\nLow: %g\nClose: %g (%.1f%%)\nVolume: " + NumToStr( V, 1 ), O, H, L, C, SelectedValue( ROC( C, 1 ) ) );
}
_SECTION_END();
_SECTION_BEGIN("Volume");
Plot( Volume, _DEFAULT_NAME(), ParamColor("Color", colorRose ), styleNoTitle | ParamStyle( "Style", styleHistogram | styleOwnScale | styleThick | styleNoLabel, maskHistogram ), 2 );
_SECTION_END();
ao = MA((H+L)/2,5) - MA((H+L)/2,34);
ac = MA((ao-MA(ao,5)),5);
greenarea = ao>Ref(ao,-1) AND ac>Ref(ac,-1);
redarea = ao<Ref(ao,-1) AND ac<Ref(ac,-1);
Plot( 2,"ribbon",
IIf( greenarea, colorGreen, IIf( redarea, colorRed, 0 )), styleOwnScale|styleArea|styleNoLabel, -0.5, 150 );
Cw5 = Ref(MA(C,5),-3);
yc8 = Ref(MA(C,8),-8);
eb13 = Ref(MA(C,13),-13);
Plot(Cw5,"",colorGreen,styleLine);"\nGreen line:eyu de chunwen.";
Plot(yc8,"",colorRed,styleLine);"Red line:eyu de yachi.";
Plot(eb13,"",colorBlue,styleLine);"Blue line:eyu de ebu(koujiang).\n";
Vlp=Param("Volume lookback period",30,20,300,10);
Vrg=MA(V,Vlp);
St = StDev(Vrg,Vlp);
Vp2 = Vrg + 2*st;;
Vp1 = Vrg + 1*st;;
Vn1 = Vrg -1*st;
Vn2 = Vrg -2*st;
rg=(H-L);
arg=Wilders(rg,30);
Cloc=C-L;
x=rg/Cloc;
xl=IIf(Cloc==0,arg,x);
Vb=V>Vrg OR V>Ref(V,-1);
ucls=xl<2;
dcls=xl>2;
mcls=xl<2.2 AND xl>1.8 ;
Vhcls=xl<1.35;
_N(Title=Name() +" "+FullName()+" "+Date()+" Open="+WriteVal(O)+
", High ="+WriteVal(H)+", Low ="+WriteVal(L)+
", Close="+WriteVal(C)+", Volume="+WriteVal(V, 1.0)+", Change="+WriteIf((C-Ref(C,-1))>0," +"," -")+
WriteVal(C-Ref(C,-1))
+" ("+WriteIf((C-Ref(C,-1))>0," +"," -")+WriteVal((C-Ref(C,-1))/Ref(C,-1)*100)+"% )" + EncodeColor(colorBlue) + "\n"+EncodeColor(colorGreen)+" cw5 = "+Cw5+EncodeColor(colorRed)+
" yc8 = "+yc8+EncodeColor(colorBlue)+" eb13 = "+eb13+
("\n Volume: ")+WriteIf(V>Vp2,EncodeColor(colorLime)+"Very High",WriteIf(V>Vp1,EncodeColor(colorLime)+" High",WriteIf(V>Vrg,EncodeColor(colorLime)+"Above Average",
WriteIf(V<Vrg AND V>Vn1,EncodeColor(colorRed)+"Less than Average",WriteIf(V<Vn1,"Low","")))))+
(EncodeColor(colorCustom12)+" Spread: ")+WriteIf(rg >(arg*2),EncodeColor(colorLime)+" Wide",WriteIf(rg>arg,EncodeColor(colorLime)+" Above Average",EncodeColor(colorRed)+" Narrow"))+
(EncodeColor(colorCustom12)+" Close: ")+WriteIf(Vhcls,EncodeColor(colorLime)+"Very High",WriteIf(ucls,EncodeColor(colorLime)+"High",WriteIf(mcls,EncodeColor(colorRed)+"Mid",
WriteIf(dcls,EncodeColor(colorRed)+"Down","Very Low")))));
Buy_larry = C < MA(C,5)*0.96 AND O < Ref(L,-1)*0.99 AND C > Ref(L,-1) AND V != 0;
PlotShapes( shapeSmallCircle*Buy_larry, colorBlue,0, H, 20);
PlotShapes( shapeHollowStar*Buy_larry, colorBlue,0, H, 20);
bStatus = WriteIf(Buy_larry, "Buy", " ");
//sStatus = WriteIf(Sell, "Sell", " ");
Filter=Buy_larry; //OR Sell;
AddColumn(V, "Volome", 1, IIf(V > Ref(V,-1), colorGreen, colorRed),-1);
AddTextColumn( FullName(), "Full name");
AddTextColumn( GroupID( 1 ), "Group name" );
AddTextColumn( SectorID( 1 ), "Sector name" );
AddTextColumn(bStatus, "Buy", 1.2, colorWhite, colorGreen,-1);
AddColumn(C, "BuyPrice");
//AddTextColumn(sStatus, "Sell", 1.2, colorWhite, colorRed,-1);
//AddColumn(O, "SellPrice");
"This is a good short term speculative trade system!!!!";
"Larry statistik";
"Signal number:2006";
"Success rate:53%.";
"High profit average:14%";
"Cover profit average:5%";
1 comments
Leave Comment
Please login here to leave a comment.
tnxxxx