Alexstream intraday for Amibroker (AFL)
alexstream over 13 years ago Amibroker (AFL)
my simple expert for intraday russian index RTS :)
Indicator / Formula
Copy & Paste Friendly
SetBarsRequired(1000000, 1000000);
SetChartOptions(2,chartShowArrows|chartShowDates);
SetTradeDelays(0,0,0,0);
P = 12;
q = 41;
a = 88;
period= 4;
mult = 1.4;
x = 1250;
ApplyStop( 2, 2, x, 0, False, 0);
showPrice = ParamToggle("Show Price","No|yes",1);
showArrows = ParamToggle("Show Arrows","No|yes",1);
showRibbon = ParamToggle("Show Ribbon","No|yes",1);
f=ATR(period);
VS[0] = Close[0];
trend[0] = 0;
HighC[0]=0;
Lowc[0]=0;
for( i = period+1; i < BarCount; i++ )
{
vs[i] = vs[i-1];
trend[i] = trend[i-1];
highC[i] = HighC[i-1];
lowc[i] = lowc[i-1];
if ((trend[i]>=0) && ( C[i] <VS[i] ))
{
trend[i] =-1;
HighC[i] = C[i];
lowc[i] = C[i];
}
if ((trend[i]<=0) && (C[i] >VS[i]))
{
trend[i]=1;
HighC[i] = C[i];
lowc[i] = C[i];
}
if (trend[i]==-1)
{
if (C[i]<lowc[i]) lowc[i] = C[i];
VS[i]= lowc[i]+ (mult*f[i]);
}
if (trend[i]==1)
{
if (C[i]>HighC[i]) HighC[i] = C[i];
VS[i]= HighC[i]-(mult*f[i]);
}
}
Buy=Cross(Trend,0) AND StochK(P,3)>q
AND Ref(StochK(P,3),-1)<=q
AND Ref(StochK(P,3),-1)<StochK(P,3)
AND StochK(P,3)>StochD(P,3,3);
Sell= Cross(StochD(P,3,3),StochK(P,3))
AND StochK(P,3)>a;
Short = Cross(0, Trend) AND StochK(P,3)<a AND Ref(StochK(P,3),-1)>=a
AND Ref(StochK(P,3),-1)>StochK(P,3)
AND StochK(P,3)<StochD(P,3,3);
Cover = Cross(StochK(P,3),StochD(P,3,3))
AND StochK(P,3)<q;
Buy=ExRem(Buy,Sell);
Sell=ExRem(Sell,Buy);
Short=ExRem(Short,Cover);
Cover=ExRem(Cover,Short);
if (ShowPrice) Plot(Close,"Close",colorBlack,styleCandle);
Plot(VS, "Vol Stop",IIf(trend==1,10,11 ),styleThick);
mkol = IIf( Trend==1, 10, 11);
if (ShowRibbon) Plot(5, "ribbon", mkol, styleOwnScale|styleArea|styleNoLabel|styleNoTitle, 0, -5);
shape = Buy * shapeUpArrow + Sell* shapeDownArrow;
if (ShowArrows) PlotShapes(IIf(Buy,shapeUpArrow,0),5,0,Graph0,-15); PlotShapes(IIf(Sell,shapeDownArrow,0),4,0,Graph0,-15); PlotShapes(IIf(Cover,shapeHollowUpArrow,0),5,0,Graph0,-15); PlotShapes(IIf(Short,shapeHollowDownArrow,0),4,0,Graph0,-15);
AlertIf( Buy, "SOUND C:\\Windows\\Media\\timeout.wav", "Sell " + C,2,1+2,1);
AlertIf( Sell, "SOUND C:\\Windows\\Media\\timeout.wav","Buy " + C,1,1+2,1);4 comments
Leave Comment
Please login here to leave a comment.
good for trade in daily time frame
It doesn’t work indicator?Why?
As usual good. Но не Грааль :-))
its awsome…………….