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 ....
For Portfolio Manager Click Here

WiseTrader Toolbox

#1 Selling Amibroker Plugin featuring:

Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
Find Out More Here

NEERU KALA BUY SELL for Amibroker (AFL)

Copy & Paste Friendly
_SECTION_BEGIN("Price");
Ticker = ParamStr("Symbol", Name() );
PlotForeign( Ticker, Ticker, ParamColor("Color", colorCycle ), ParamStyle("Style") | GetPriceStyle() ); 
_SECTION_END();
_SECTION_BEGIN("MISHRI LAL NARENDRA KUMAR KALA");
SetChartBkColor(ParamColor("Outer panel color ",colorLightYellow));
SetChartBkColor(ParamColor("BackGround Color", colorDarkGrey));


intraday = ParamToggle("Message Board","Show|Hide",0);
showsl = ParamToggle("Stop Loss Line", "Show|Hide", 0);
 
m=IIf(ParamList("select type","Message Board|Message Board1")=="Message Board",-1,0);


messageboard = ParamToggle("Message Board1","Show|Hide",0);
showsl = ParamToggle("Stop Loss Line", "Show|Hide", 0);
m1 = ParamToggle("Message Board1","Show|Hide",0);

intraday = ParamToggle("Message Board","Show|Hide",0);
showsl = ParamToggle("Stop Loss Line", "Show|Hide", 0);
 _SECTION_BEGIN("swing1");
no=22;
res=HHV(H,no);
sup=LLV(L,no);
avd=IIf(C>Ref(res,-1),1,IIf(C<Ref(sup,-1),-1,0));
avn=ValueWhen(avd!=0,avd,1);
supres=IIf(avn==1,sup,res);
a=Cross(C,supres);
b=Cross(supres,C);
style = a * styleStaircase + b * styleStaircase;
PlotShapes(a,style, IIf(a,colorGreen,colorRed), 0, IIf(a,Low,High));
Plot(supres,"Swing",colorYellow,styleStaircase);
_SECTION_END();



style = a * styleStaircase + b * styleStaircase;

PlotShapes(a,style, IIf(a,colorGreen,colorRed), 0, IIf(a,Low,High));
if (showsl == 0) Plot(supres,"Stop Loss",colorCustom14,styleDots);
exitlong = Cross(supres, H);
PlotShapes(exitlong * shapeNone, colorBlack,0,H,-10);
exitshort = Cross(L, supres);
PlotShapes(exitshort * shapeNone, colorBlack,0,L,-15);

Buy = exitshort;
Sell = exitlong;
//Short = Sell;
//Cover = Buy;
Buy = ExRem(Buy,Sell);
Sell = ExRem(Sell,Buy);
//Short = ExRem(Short, Cover);
//Cover = ExRem(Cover, Short);
AlertIf( Buy, "", "BUY ABOVE @ " + C, 1 );
AlertIf( Sell, "", "SELL BELOW @ " + C, 2 );

for (i=BarCount-1; i>1; i--) {
  if (Buy[i] == 1) {
    entry  = O[i];
    sig = "  BUY ";
    sl = supres[1];
    tar1 = entry + (entry * .0040);
    tar2 = entry + (entry * .0080);
    tar3 = entry + (entry * .0120);
    tar4 = entry + (entry * .0160);
    tar5 = entry + (entry * .0200);
    tar6 = entry + (entry * .0240);
    tar7= entry + (entry * .0280);
    tar8 = entry + (entry * .0320);
 tar9 = entry + (entry * .0360);
tar10 = entry + (entry * .0400);
    tar11 = entry + (entry * .0440);
    tar12 = entry + (entry * .0480);
    tar13= entry + (entry * .0520);
    tar14= entry + (entry * .0560);
    tar15= entry + (entry * .0600);

    tar16= entry + (entry * .0640);




    bars = i;
    i = 0;
  }
  if (Sell[i] == 1) {
    sig = "  SELL";
    entry = O[i];
    sl = supres[i];
    tar1 = entry - (entry * .0040);
    tar2 = entry - (entry * .0080);
    tar3 = entry - (entry * .0120);
    tar4 = entry - (entry * .0160);
    tar5 = entry - (entry * .0200);
    tar6 = entry - (entry * .0240);
    tar7= entry - (entry * .0280);
    tar8= entry - (entry * .0320);
    tar9= entry - (entry * .0360);
    tar10 = entry - (entry * .0400);
    tar11 = entry - (entry * .0440);
    tar12 = entry - (entry * .0480);
    tar13= entry - (entry * .0520);
    tar14= entry - (entry * .0560);
    tar15= entry - (entry * .0600);

    tar16= entry - (entry * .0640);









   
    bars = i;
    i = 0;
  }
}

Offset = 20;
Clr = IIf(sig == "BUY ", colorLime, colorRed);
ssl = IIf(bars == BarCount-1, supres[BarCount-1], Ref(supres, -1));
sl = ssl[BarCount-1];
//Plot(LineArray(bars-Offset, tar1, BarCount, tar1,1), "", Clr, styleLine|styleDots, Null, Null, Offset);
Plot(LineArray(bars-Offset, tar2, BarCount, tar2,1), "", Clr, styleLine|styleDots, Null, Null, Offset);
//Plot(LineArray(bars-Offset, tar3, BarCount, tar3,1), "", Clr, styleLine|styleDots, Null, Null, Offset);
Plot(LineArray(bars-Offset, tar6, BarCount, tar6,1), "", Clr, styleLine|styleDots, Null, Null, Offset);
Plot(LineArray(bars-Offset, tar16, BarCount, tar16,1), "", Clr, styleLine|styleDots, Null, Null, Offset);


//Plot(LineArray(bars-Offset, sl, BarCount, sl,1), "", colorDarkRed, styleLine|styleLine, Null, Null, Offset);
Plot(LineArray(bars-Offset, entry, BarCount, entry,1), "", colorGreen, styleLine|styleLine, Null, Null, Offset);


//Plot(LineArray(bars-Offset, sl, BarCount, sl,1), "", colorDarkRed, styleLine|styleLine, Null, Null, Offset);
Plot(LineArray(bars-Offset, entry, BarCount, entry,1), "", colorGreen, styleLine|styleLine, Null, Null, Offset);

for (i=bars; i <BarCount;i++)
{
PlotText(""+sig+"@"+entry, BarCount+1,entry,Null,colorBlue);
PlotText("T1@"+tar1,BarCount+3,tar1,Null,Clr);
//PlotText("T2@"+tar2,BarCount+3,tar2,Null,Clr);
//PlotText ("T3@"+tar3,BarCount+3,tar3,Null,Clr);

}

printf("Last " + sig + " Signal came " + (BarCount-bars) + " bars ago");
printf("\n" + sig + " @ : " + entry + "\nStop Loss : " + sl + " (" + WriteVal(IIf(sig == "SELL",entry-sl,sl-entry), 2.2) + ")"+ "\nTarget_1 : " + tar1 + "\nTarget_2 : " + tar2 + "\nTarget_3 : " + tar3);
printf("\nCurrent P/L : " + WriteVal(IIf(sig == "BUY ABOVE",(C-entry),(entry-C)),2.2));

if (intraday == 0) {
  GfxSelectFont( "Tahoma", 13, 400 );
  GfxSetBkMode( 1 );
  GfxSetTextColor( colorWhite );

  if (sig =="BUY")
    GfxSelectSolidBrush( colorGreen ); // this is the box background color
  else
    GfxSelectSolidBrush( colorGreen ); // this is the box background color

  pxHeight = Status( "pxchartheight" ) ;
  xx = Status( "pxchartwidth");
  Left = 1100;
  width =410;
  x = 5;
  x4 = 160;

  y = Status( "pxchartheight" );

  GfxSelectPen( colorDarkRed, 1); // broader color
  GfxRoundRect( x, y - 600, x4, y , 12, 12) ;
  GfxTextOut( ( "  "), 88, y-500) ;
  
  GfxTextOut( ("" + WriteIf(sig =="Buy",sig + " @ ",sig + " @") + " : " + entry) ,13, y-460);
  GfxTextOut( ("Trailing SL : " + sl + " "), 13, y-440);
  GfxTextOut( ("TGT:1 : " + tar1), 13, y -420);
  GfxTextOut( ("TGT:2 : " + tar2), 13,y-400);
GfxTextOut( ("TGT:3 : " + tar3), 13,y-380);
GfxTextOut( ("TGT:4 : " + tar4), 13,y-340);
GfxTextOut( ("TGT:5: " + tar5), 13,y-320);
GfxTextOut( ("TGT:6 : " + tar6), 13,y-300);
GfxTextOut( ("TGT:7 : " + tar7), 13,y-280);
GfxTextOut( ("TGT:8: " + tar8), 13,y-260);
GfxTextOut( ("TGT:9 : " + tar9), 13,y-240);
GfxTextOut( ("TGT:10 : " + tar10), 13,y-200);
GfxTextOut( ("TGT:11 : " + tar11), 13,y-180);
GfxTextOut( ("TGT:12: " + tar12), 13,y-160);
GfxTextOut( ("TGT:13 : " + tar13), 13,y-140);
GfxTextOut( ("TGT:14 : " + tar14), 13,y-120);
GfxTextOut( ("TGT:15: " + tar15), 13,y-100);
GfxTextOut( ("TGT:16: " + tar16), 13,y-80);




}

_SECTION_BEGIN("Wilders");
P = ParamField("Price field",-1);
Periods = Param("Periods", 15, 2, 300, 1, 10 );
Plot( Wilders( P, Periods ), _DEFAULT_NAME(), ParamColor( "Color", colorCycle ), ParamStyle("Style") ); 
_SECTION_END();
Back