Stock Portfolio Organizer
The ultimate porfolio management solution.
Shares, Margin, CFD's, Futures and Forex
EOD and Realtime
Dividends and Trust Distributions
And Much More ....
WiseTrader Toolbox
#1 Selling Amibroker Plugin featuring:
Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
stock xray plz help me to remove some error for Amibroker (AFL)
Copy & Paste Friendly
Back
_SECTION_BEGIN("MAD"); T=80; KMA=((C-MA(C,T))/MA(C,T))*100; Graph0=KMA; Graph0BarColor=IIf(KMA>0,5,4); cx=Param("cxposn",810,0,1200,1); cy=Param("cyposn",37,0,1000,1); GfxSetBkColor(ColorRGB(200,50,100)); GfxSelectFont( "Bodoni MT",22,98, False); GfxSetTextColor( colorYellow); GfxTextOut("LTP. "+C+" ", cx, cy ); _SECTION_END(); _SECTION_BEGIN("Name"); GfxSetOverlayMode(1); GfxSelectFont("Tahoma", Status("pxheight")/20); GfxSetTextAlign( 6 ); GfxSetTextColor( ColorHSB( 10, 300, 20 ) ); GfxSetBkMode(0); GfxTextOut( Name(), Status("pxwidth")/2, Status("pxheight")/20 ); _SECTION_BEGIN("Time Left"); function GetSecondNum() { Time = Now( 4 ); Seconds = int( Time % 100 ); Minutes = int( Time / 100 % 100 ); Hours = int( Time / 10000 % 100 ); SecondNum = int( Hours * 60 * 60 + Minutes * 60 + Seconds ); return SecondNum; } RequestTimedRefresh( 1 ); TimeFrame = Interval(); SecNumber = GetSecondNum(); Newperiod = SecNumber % TimeFrame == 0; SecsLeft = SecNumber - int( SecNumber / TimeFrame ) * TimeFrame; SecsToGo = TimeFrame - SecsLeft; x=Param("xposn",300,0,1000,1); y=Param("yposn",50,0,1000,1); GfxSelectSolidBrush( ColorRGB( 230, 230, 230 ) ); GfxSelectPen( ColorRGB( 223, 100, 230 ), 3 ); if ( NewPeriod ) { GfxSelectSolidBrush( colorYellow ); GfxSelectPen( colorYellow, 2 ); //Say( "New period" ); } GfxRoundRect( x+135, y+538, x+265, y+512, 0,0 ); GfxSetBkMode(1); GfxSelectFont( "Arial", 14, 800, False ); GfxSetTextColor( colorBlack ); GfxTextOut( "Timeleft"+" : "+NumToStr( SecsToGo, 1.0 ), x+200, y+515 ); _SECTION_END(); _SECTION_END(); _SECTION_BEGIN("mo"); mo(); _SECTION_END(); _SECTION_BEGIN("BS-Text"); ABC=SS_C1(); CD=SS_C2(); AA = SS_A1(); BB = SS_B1(); pos = 4.9*ATR(5); for( i = 0; i < BarCount; i++ ) { if( ABC[i] ) PlotText( "BUY * STOCKXRAY @\n" +AA[i], i, Low[i] - pos[i], colorAqua, Offset=-10 ); if( CD[i] ) PlotText( "SELL * STOCKXRAY @\n" + BB[i], i, Low[i] + pos[i], colorRose, Offset=-10 ); } _SECTION_END(); _SECTION_BEGIN("ADX"); range = Param("ADX Periods", 7, 2, 200, 1 ); Col_adx = IIf(ADX(range) > Ref(ADX(range),-1) AND ADX(range) > 20,colorBlue, colorGrey40); em = Param("EMA Of ADX",3,1,20,1); p = EMA(PDI(range),em); m = EMA(MDI(range),em); //Plot( ADX(range), _DEFAULT_NAME(), Col_adx , ParamStyle("ADX style", styleThick ) ); btp = BBandTop( P, 5, 0.4 ); bbp = BBandBot( P, 5, 0.4 ); btm = BBandTop( m, 5, 0.4 ); bbm = BBandBot( m, 5, 0.4 ); //Plot(btp , "" , colorDarkGreen, styleDashed ); //Plot(bbp , "" , colorDarkGreen, styleDashed ); //Plot( btm, "" , colorDarkRed, styleDashed ); //Plot( bbm, "" , colorDarkRed, styleDashed ); Col_p = IIf(p > btp, colorBrightGreen,colorDarkGreen); Col_m = IIf(m > btm,colorRed,colorDarkRed); //Plot( p, "+DI", Col_p, styleDots ); //Plot( M, "-DI", Col_m, styleDots ); Buy = ADX(range) > MDI(range) AND PDI(range) > MDI(range); Sell = ADX(range) > PDI(range) AND MDI(range) > PDI(range); Buy_sell = IIf(Buy,colorGreen,IIf(Sell,colorRed,colorBlack)); trend = IIf(col_p==colorBrightGreen,colorBrightGreen,IIf(col_m==colorRed,colorRed,IIf(PDI(range) > MDI(range),colorDarkGreen,colorDarkRed))); //Plot(6, "", Buy_sell, styleOwnScale| styleArea|styleNoLabel,-0.5,100); _SECTION_END(); _SECTION_BEGIN("B"); SetChartBkColor(colorPaleBlue); Buy_p = p > btp OR m < bbm; Buy_p1 =p > btp AND m < bbm; Sell_m = m > btm OR p < bbp; Sell_m1 = m > btm AND p < bbp; bs = IIf(O>bb,colorBrightGreen,IIf(O<aa,colorRed,IIf(Buy_p AND Sell_m,colorWhite,IIf(Buy_p,colorBlue,IIf(Sell_m,colorPink,colorBlack))))); HaClose =EMA((O+H+L+C)/4,3); HaOpen = AMA( Ref( HaClose, -1 ), 0.5 ); HaHigh = Max( H, Max( HaClose, HaOpen ) ); HaLow = Min( L, Min( HaClose, HaOpen ) ); PlotOHLC( HaOpen, HaHigh, HaLow, HaClose,"" , bs, styleCandle| styleNoLabel ); _SECTION_END(); _SECTION_BEGIN("MSG"); SS_Mo(); E30 = SS_E1(); F30 = SS_E2(); GO=(CD+(E30*0.0038)); JO=(ABC-(E30*0.0038)); so=(CD+(E30*0.0055)); PO=(ABC-(E30*0.0055)); ABC=SS_C1(); CD=SS_C2(); messageboard = ParamToggle("","",0); exitlong = CD; exitshort = ABC; BT1 = SS_BT1(); BT2 = SS_BT2(); BT3 = SS_BT3(); BT4 = SS_BT4(); ST1 = SS_ST1(); ST2 = SS_ST2(); ST3 = SS_ST3(); ST4 = SS_ST4(); for(i=BarCount-1;i>1;i--) { if(ABC[i] == 1) { BT11 = BT1[i]; BT22 = BT2[i]; BT33 = BT3[i]; BT44 = BT4[i]; entry = AA[i]; sig = "ABC"; tar1 = BT11; tar2 = BT22; tar3 = BT33; tar4 = BT44; bars = i; i = 0; } if(CD[i] == 1) { sig = "CD"; ST11 = ST1[i]; ST22 = ST2[i]; ST33 = ST3[i]; ST44 = ST4[i]; entry = BB[i]; tar1 = ST11; tar2 = ST22; tar3 = ST33; tar4 = ST44; bars = i; i = 0; } } Offset = 20; Clr = IIf(sig == "ABC", colorBlue,colorDarkRed); Plot(LineArray(bars-Offset, tar1, BarCount, tar1,1), "", Clr, styleLine, Null, Null, Offset); Plot(LineArray(bars-Offset, tar2, BarCount, tar2,1), "", Clr, styleLine, Null, Null, Offset); Plot(LineArray(bars-Offset, tar3, BarCount, tar3,1), "", Clr, styleLine, Null, Null, Offset); Plot(LineArray(bars-Offset, tar4, BarCount, tar4,1), "", Clr, styleLine, Null, Null, Offset); for (i=bars; i <BarCount;i++) { //PlotText(""+sig+"@"+entry, BarCount+4,entry,Null,colorBlue); PlotText("T1*"+tar1,BarCount+4,tar1,Null,Clr); PlotText("T2* "+tar2,BarCount+4,tar2,Null,Clr); PlotText ("LT1* "+tar3,BarCount+4,tar3,Null,Clr); PlotText ("LT2* "+tar4,BarCount+4,tar4,Null,Clr); } printf("Last " + sig + " Signal came " + (BarCount-bars) + " bars ago"); printf("\n" + sig + " @ : " + entry + "\nStop Loss : " + " (" + WriteVal(IIf(sig == "CD",entry-C,C-entry), 2.2) + ")"+ "\nTarget_1 : " + tar1 + "\nTarget_2 : " + tar2 + "\nTarget_3 : " + tar3); printf("\nCurrent P/L : " + WriteVal(IIf(sig == "ABC",(C-entry),(entry-C)),2.2)); if (messageboard == 0 ) { GfxSelectFont( "Tahoma", 10, 100 ); GfxSetBkMode( 1 ); GfxSetTextColor( colorWhite ); if ( sig =="ABC") { GfxSelectSolidBrush( colorBlue ); } else { GfxSelectSolidBrush( colorRed ); } pxHeight = Status( "pxchartheight" ) ; xx = Status( "pxchartwidth"); Left = 1100; width = 310; x = 3; x2 = 210; y = pxHeight; GfxSelectPen( colorWhite, 5); GfxRoundRect( x, y - 180, x2, y -1, 80, 150 ) ; GfxTextOut( ( " * STOCKXRAY MAGIC * "),101,y-173); GfxSetTextColor(ColorRGB(100,300,200)); GfxTextOut( (" STOP LOSS : " + WriteVal(IIf(sig == "ABC",(E30-SO),(E30-PO)),2.1)), 90, y-117);; GfxTextOut( (" SECURED SL # REVERSE TREND "), 105, y-100); GfxSetTextColor( colorWhite ); GfxTextOut( ("TGT:1 : " + tar1), 101, y -82); GfxTextOut( ("TGT:2 : " + tar2), 100,y-62); GfxSetTextColor( colorGold ); GfxTextOut( ("LONG TGT 1 : " + tar3), 100,y-43); GfxTextOut( ("LONG TGT 2 : " + tar4), 100,y-24); GfxSetTextColor( colorBrightGreen ); GfxTextOut( (" CURRENT P/L : " + WriteVal(IIf(sig == "ABC",(C-entry),(entry-C)),2.1)), 90, y-155); GfxSelectFont("Tahomabold", 10.4, 100 ); GfxSetTextColor(ColorHSB(30,4,250)); GfxTextOut( (" BEST OPPORTUNITY * " + WriteVal(IIf(sig == "ABC",(E30-GO),(E30-JO)),2.1)), 103, y-135);; GfxSetTextColor(ColorRGB(10,250,250)); GfxTextOut( ( " Develop By "),950,y-40); GfxSetTextColor(ColorRGB(10,250,250)); GfxTextOut( ( "* STOCKXRAY SYSTEM * "),950,y-20); } _SECTION_BEGIN("Breakout"); breakout = ParamToggle("BREKOUT","No|Yes",1); PP1 = SS_PP1(); PPA1 = SS_PPA1(); PP2 = SS_PP2(); PPA2 = SS_PPA2(); Asd=IIf(breakout,PPA1,PPA2); Lkj=IIf(breakout,PP1,PP2); Plot(IIf(breakout,PPA1,PPA2),"Best Up",colorBlack,4+8+2048); Plot(IIf(breakout,PP1,PP2),"Best Dn",colorBlack,4+8+2048); _SECTION_END(); _SECTION_END(); //Plot( Volume, _DEFAULT_NAME(), ParamColor("Color", colorPink ), ParamStyle( "Style", styleHistogram | styleOwnScale | styleThick, maskHistogram ), 2 ); _SECTION_BEGIN("zone"); TimeFrameSet(60*in1Minute); //SS_Z1 st = SS_Z1(); TimeFrameRestore(); // restore time frame to original uptrendf=TimeFrameExpand(st , 60*in1Minute); //downtrendf=TimeFrameExpand( downtrend, 15*in1Minute); Colorf=TimeFrameExpand (colorGold, 60*in1Minute); Plot( 2, "zone",IIf(O>uptrendf,colorBrightGreen,colorRed),styleOwnScale|styleArea|styleNoLabel,1, 100,1); _SECTION_END(); _SECTION_BEGIN("93"); ORBHigh = SS_Z2(); ORBLow = SS_Z3(); yy=Cross(f30,ORBHigh); tt=Cross(ORBLow,f30); PlotShapes(shapeStar*yy,colorWhite,0,O,-20); PlotShapes(shapeStar*tt,colorBlack,0,O,20); ww=Cross(f30,tar2); qq=Cross(tar2,f30); PlotShapes(shapeHollowStar*ww,colorDarkBlue,0,L,-20); PlotShapes(shapeHollowStar*qq,colorViolet,0,H,20); _SECTION_END(); _SECTION_BEGIN("Volume"); cx = Param("cxposn",1000,0,1200,1); cy = Param("cyposn", 6,0,1000,10 ); GfxSelectFont( " Arial ", 18, 98, False ); GfxSetTextColor( colorWhite ); GfxTextOut("Volume " +Volume+ "", cx-300,cy +555); _SECTION_END(); _SECTION_BEGIN("Title"); DDayO = TimeFrameGetPrice("O", inDaily); DHiDay = TimeFrameGetPrice("H", inDaily); DLoDay = TimeFrameGetPrice("L", inDaily); prvC = TimeFrameGetPrice("C", inDaily, -1);//close Title = EncodeColor(ColorRGB(10,10,350))+"* STOCKXRAY * "+EncodeColor(colorWhite)+ Name() + ", " + Interval(2) + ", " + Date() + EncodeColor(colorBrightGreen) + "\nO " + EncodeColor(colorBrightGreen) + O + ", H : " + H + ", L : " + L+ EncodeColor(colorOrange) + " ~ Prev Close : " + EncodeColor(colorPink) + prvC +EncodeColor(colorGold)+ "\n Day-Open : " +DDayO + " Day-High : " +DHiDay + " Day-Low : "+ DLoDay ; _SECTION_END();