Skip to main content

Scalper High Low Bracket for Amibroker (AFL)

Bend over 11 years ago Amibroker (AFL)

  • Rating:
    3 / 5 (Votes 6)
  • Tags:
    amibroker

I found out this indicator from Multicharts and ported it in AFL. It helps me fast placing my order in price ladder when I use stop orders. Change the tick offset according to the instrument you trade. And if change the sound file to your liking.

Screenshots

Indicator / Formula

Copy & Paste Friendly
//ScalperHighLow Bracket By JRA Jan 2015
HX=Ref(H,-1);
LX=Ref(L,-1);
TicksOffset= Param("TicksOffset",0.0001,0.0001,0.50,0.0001);//NofTicksAboveorBelow
y0=LastValue(HX)+TicksOffset; 
y1=LastValue(LX)-TicksOffset; 
Offset = 2;
for(i=BarCount-2;i>1;i--)
{
bars = i;
i = 0;
}
Plot(LineArray(bars-Offset, y0, BarCount, y0,1), "", colorDarkRed, styleLine|styleLine|stylenolabel, Null, Null, Offset);
Plot(LineArray(bars-Offset, y1, BarCount, y1,1), "", colorDarkRed, styleLine|styleLine|stylenolabel, Null, Null, Offset);
for (i=bars; i <BarCount;i++)
{
if (C[i]>y0)
color[i]=colorblue;
else
color[i] = Null;
PlotText(""+Y0, BarCount+1,Y0,Null,color[i]);
AlertIF( C[i]>y0, "SOUND C:\\Windows\\Media\\ringout.wav", "Audio alert", 1 );
}
for (i=bars; i <BarCount;i++)
{
if (C[i]<y1)
color[i]=colorred;
else
color[i] = Null;
PlotText(""+Y1, BarCount+1,Y1,Null,color[i]);
AlertIF( C[i]<y1, "SOUND C:\\Windows\\Media\\ringout.wav", "Audio alert", 1 );
}

0 comments

Leave Comment

Please login here to leave a comment.