easylivetrade afl for freeafl in amibroker

johnnypareek

Well-Known Member
#21
sir i am subscribing the auto buy sell signal from easylivetrade.com thera fees is rs.10100.i have no experiance about this plz give me your valuable decision.
Don't subscribe.

here it is

HTML:
wc = TimeFrameCompress( Close, in15Minute ); 

/* now the time frame is still unchanged (say daily) and our MA will operate on daily data */ 
dailyma = EMA( C, 39 ); 

/* but if we call MA on compressed array, it will give MA from other time frame */ 
weeklyma = EMA( wc, 39 ); // note that argument is time-compressed array 



weeklyma = TimeFrameExpand( weeklyma, in15Minute ); // expand for display 

Plot( weeklyma, "WeeklyMA", colorBlue ); 

wc = TimeFrameCompress( Close, in15Minute ); 

/* now the time frame is still unchanged (say daily) and our MA will operate on daily data */ 
dailyma = EMA( C, 104 ); 

/* but if we call MA on compressed array, it will give MA from other time frame */ 
weeklyma = EMA( wc, 104 ); // note that argument is time-compressed array 


weeklyma = TimeFrameExpand( weeklyma, in15Minute ); // expand for display 

Plot( weeklyma, "WeeklyMA", colorBrightGreen ); 
wc = TimeFrameCompress( Close, in15Minute ); 

/* now the time frame is still unchanged (say daily) and our MA will operate on daily data */ 
dailyma = MA( C, 104 ); 

/* but if we call MA on compressed array, it will give MA from other time frame */ 
weeklyma = MA( wc, 104 ); // note that argument is time-compressed array 


weeklyma = TimeFrameExpand( weeklyma, in15Minute ); // expand for display 

Plot( weeklyma, "WeeklyMA", colorLightGrey ); 
_SECTION_END();

_SECTION_BEGIN("Price");
SetChartOptions(0,chartShowArrows|chartShowDates);
_N(Title = StrFormat("{{NAME}} - {{INTERVAL}} {{DATE}} Open %g, Hi %g, Lo %g, Close %g (%.1f%%) {{VALUES}}", O, H, L, C, SelectedValue( ROC( C, 1 ) ) ));
Plot( C, "Close", ParamColor("Color", colorWhite ), styleNoTitle | ParamStyle("Style") | GetPriceStyle() ); 
_SECTION_END();

_SECTION_BEGIN("swing1");
no=20;
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;

_SECTION_END();


DayH = SelectedValue(TimeFrameGetPrice("H", inDaily));// yesterdays high 
DayL = SelectedValue(TimeFrameGetPrice("L", inDaily));//low 
DayH1 = SelectedValue(TimeFrameGetPrice("H", inDaily, -1));// yesterdays high 
DayL1 = SelectedValue(TimeFrameGetPrice("L", inDaily, -1));//low 
DayH2 = SelectedValue(TimeFrameGetPrice("H", inDaily, -2));// yesterdays high 
DayL2 = SelectedValue(TimeFrameGetPrice("L", inDaily, -2));//low 

Range = ((DayH +DayH1  +DayH2)/3 - (DayL+DayL1+DayL2)/3);
sr1= (Range *0.292)+DayL;
sr2= Dayh-(Range *0.33);
sr3= (Range *0.702)+DayL;
sr4= DayH-(Range *0.655);

style = styleLine | styleNoRescale|styleLine; 
Plot(sr1, "SR1",colorWhite ,styleDashed|styleNoRescale|styleThick);
Plot(sr2, "SR2",colorGold  ,styleDashed|styleNoRescale|styleThick);
Plot(sr3, "SR3",colorPink  , styleDashed|styleNoRescale|styleThick);
Plot(sr4, "SR4",colorOrange ,styleDashed|styleNoRescale|styleThick);

Bars_so_far_today = 1 + BarsSince( Day() != Ref(Day(), -1));
TT=  RSIa(C,60);
StartBar = ValueWhen(TimeNum() == 090000, BarIndex());
TodayVolume = Sum(TT,Bars_so_far_today);
IIf (BarIndex() >= StartBar, VWAP = Sum (C * TT, Bars_so_far_today  ) / TodayVolume,0);
Plot (VWAP,"VWAP",colorOrange,4 +8+2048 );

_SECTION_BEGIN("Volume");
Plot( Volume, _DEFAULT_NAME(), ParamColor("Color", colorBrown ), styleNoTitle | ParamStyle( "Style", styleHistogram | styleOwnScale | styleThick | styleNoLabel, maskHistogram ), 2 );
_SECTION_END();
Plot(supres,"Swing",colorYellow,styleStaircase);

SetChartBkGradientFill( ParamColor("BgTop", colorBlack),

ParamColor("BgBottom", colorBlack),ParamColor("titleblock", colorBlack));

GraphXSpace = 5;



_SECTION_BEGIN("EMA");
P = ParamField("Price field",-1);
Periods = Param("Periods", 13);
Plot( EMA( P, Periods ), _DEFAULT_NAME(), ParamColor( "Color", colorCycle ), ParamStyle("Style") ); 
_SECTION_END();

_SECTION_BEGIN("DEMA");
P = ParamField("Price field",-1);
Periods = Param("Periods", 65, 2, 3000, 1, 10 );
Plot( DEMA( P, Periods ), _DEFAULT_NAME(), ParamColor( "Color", colorAqua ), ParamStyle("Style") ); 
_SECTION_END();

A = DEMA (H,65);
B = EMA (H,39);
G = DEMA (L,65);
I = EMA(L,39);
D = Min (G,I);
E = Max (A,B);
/* Buy or Sell Condition */
Buy =Cover= Cross(Close,E);
Sell = Short=Cross(D,Close);
Buy = ExRem(Buy,Sell);
Sell = ExRem(Sell,Buy);
SellPrice=ValueWhen(Sell,C,1);
BuyPrice=ValueWhen(Buy,C,1);

Filter = Buy OR Sell;
/* Exploration Parameters */
AddTextColumn( FullName(), "Company Name" );
AddColumn( Buy, "Buy", 1 );
AddColumn( Sell, "Sell", 1 );
AddColumn( C, "Close", 1.3 );
AddColumn( H, "High", 1.3 );

Title = EncodeColor(colorWhite)+ "Saihaj Arjit Rainy Rimple (SARR) Trading System" + " - " +  Name() + " - " + EncodeColor(colorRed)+ Interval(2) + EncodeColor(colorWhite) +
 "  - " + Date() +" - "+"\n" +EncodeColor(colorRed) +"Op-"+O+"  "+"Hi-"+H+"  "+"Lo-"+L+"  "+
"Cl-"+C+"  "+ "Vol= "+ WriteVal(V)+"\n"+ 
EncodeColor(colorLime)+
WriteIf (Buy , " GO LONG / Reverse Signal at "+C+"  ","")+
WriteIf (Sell , " EXIT LONG / Reverse Signal at "+C+"  ","")+"\n"+EncodeColor(colorWhite)+
WriteIf(Sell , "Total Profit/Loss for the Last Trade Rs."+(C-BuyPrice)+"","")+
WriteIf(Buy  , "Total Profit/Loss for the Last trade Rs."+(SellPrice-C)+"","");

PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorGreen, 0, L, Offset=-40);
PlotShapes(IIf(Buy, shapeSquare, shapeNone),colorLime, 0,L, Offset=-50);                      
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone),colorWhite, 0,L, Offset=-45); 
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorRed, 0, H, Offset=40);
PlotShapes(IIf(Sell, shapeSquare, shapeNone),colorOrange, 0,H, Offset=50);                      
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone),colorWhite, 0,H, Offset=-45);
_SECTION_END();
 
Last edited:
#23
why many are akning this one , is it more tradable or profitable in your views in traders experience.

easylivetrade and autolivetrade both probably using the above given afl only as per viewing their charts.

one doubt I am getting in these afls , in this afl the (SL) trend line comes down sometimes below while running upward movements within the same direction ,

it is unlike the NMA afl which never comes down once goes up will stand there , if comes down means changing the trend there itself.
why this is like so and how to trade with it these things still I want to know.
 

johnnypareek

Well-Known Member
#24
This is what u r looking for.

HTML:
_SECTION_BEGIN("MetaCandle");
BgColor=ParamColor("BgColor", colorBlack);
SetChartBkGradientFill( BgColor, BgColor, BgColor); 
upcolor=ParamColor("Up color ", colorGreen);
downcolor=ParamColor("Down color ", colorRed);
barcolor=IIf(C>Ref(C, -1), upcolor, downcolor);
Insidecolor=IIf(C<O, barcolor, BgColor);
SetBarFillColor(Insidecolor);
//PlotOHLC( Open, High, Low, Close, " ", barcolor, styleCandle | styleThick );
SetChartOptions(0, chartShowArrows|chartShowDates);
//SetChartBkColor(ParamColor("Outer Panel", colorPaleBlue));
//SetChartBkGradientFill(ParamColor("Upper Chart", 1), ParamColor("Lower Chart", 23));
GraphXSpace=Param("GraphXSpace", 10, 0, 100, 1);
dec = (Param("Decimals", 2, 0, 7, 1)/10)+1;
bi = BarIndex();
Lbi = LastValue(BarIndex());
sbi = SelectedValue(bi);
x1= BarCount-1;
Title = EncodeColor(55)+ Title = Name() + " " + EncodeColor(32) + Date() +
" " + EncodeColor(5) + "{{INTERVAL}} " +
EncodeColor(55)+ " Open = "+ EncodeColor(52)+ WriteVal(O, dec) + 
EncodeColor(55)+ " High = "+ EncodeColor(5) + WriteVal(H, dec) +
EncodeColor(55)+ " Low = "+ EncodeColor(32)+ WriteVal(L, dec) + 
EncodeColor(55)+ " Close = "+ EncodeColor(52)+ WriteVal(C, dec)+
EncodeColor(55)+ " Volume = "+ EncodeColor(52)+ WriteVal(V, 1);

TimeFrameSet(inDaily);
DayHigh = LastValue(H);
DayLow = LastValue(L);
TimeFrameRestore();

//Title = Date() + ", Op=" + Open + ", Hi=" + High + ", Lo=" + Low + ", LTP=" + Close + ", Change= " + SelectedValue( ROC( C, 1 ) ) + "%" + "n Today`s High=" + DayHigh + ", Today`s Low=" + DayLow + "  PRIME SYSTEM" ;


prev=AMA2(C, 1, 0);
d=IIf(C>Ref(Max(Max(H, Ref(H, -20)), Max(Ref(H, -10), Ref(H, -15))), -1), Min(Min(L, Ref(L, -20)), Min(Ref(L, -10), Ref(L, -15))), 
IIf(C<Ref(Min(Min(L, Ref(L, -20)), Min(Ref(L, -10), Ref(L, -15))), -1), Max(Max(H, Ref(H, -20)), Max(Ref(H, -10), Ref(H, -15))), PREV));
a=Cross(Close, d);
b=Cross(d, Close);
state=IIf(BarsSince(a)<BarsSince(b), 1, 0);
s=state>Ref(state, -1);
ss=state<Ref(state, -1);
sss=state==Ref(state, -1);
col=IIf(state == 1, 51, IIf(state ==0, 4, 1));
Plot(C, "", Col, 64);
Buy = s;
Sell = ss;
shape = Buy * shapeUpArrow + Sell * shapeDownArrow;
PlotShapes(shape, IIf(Buy, colorGreen, colorRed), 0, IIf(Buy, Low, High));
PlotShapes(IIf(Buy, shapeSquare, shapeNone), colorGreen, 0, L, Offset=-10);
PlotShapes(IIf(Buy, shapeSquare, shapeNone), colorLime, 0, L, Offset=-20);
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone), colorWhite, 0, L, Offset=-15);
PlotShapes(IIf(Sell, shapeSquare, shapeNone), colorRed, 0, H, Offset=20);
PlotShapes(IIf(Sell, shapeSquare, shapeNone), colorOrange, 0, H, Offset=30);
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone), colorWhite, 0, H, Offset=-25);
//WriteIf(s, "EXIT all Short positionsnif trading long positions, enter long Now-nOR at the market price on tomorrow's Open with stop="+EncodeColor(4)+WriteVal(L+.75*ATR(5), 1.4)+", ", "");
//WriteIf(ss, "exit all long positions today with a Market On Close (MOC) ordernOR at the market price on tomorrow's Open with stop="+EncodeColor(4)+WriteVal(Ref(H+.75*ATR(5), -1), 1.4)+", ", "");
//WriteIf( sss, "No trading signals today.", "") ;


dist = 0.8*ATR(10);
dist1 = 2*ATR(10);
for( i = 0; i < BarCount; i++ )
{
if( Buy[i] )
{
PlotText( "nBuy:" + L[ i ] + "nT= " + (L[i]*1.005) + "nSL= " + (L[i]*0.9975), i, L[ i ]-dist[i], colorGreen, colorWhite );
}
if( Sell[i] )
{
PlotText( "Sell:" + H[ i ] + "nT= " + (H[i]*0.995) + "nSL= " + (H[i]*1.0025), i, H[ i ]+dist1[i], colorRed, colorWhite );
}
}


Filter = s OR sss OR sss ;
AddColumn(C, "close", 1.2);
AddColumn( IIf( s, 66, 1 ), "buy", formatChar, 1, bkcolor =IIf (s, colorYellow, colorPink ));
AddColumn( IIf( Ss, 83, 1 ), "sell", formatChar, 1, bkcolor =IIf (Ss, colorPink, colorWhite ));
AddColumn( IIf( sss, 87, 1 ), "wait", formatChar, 1, bkcolor =IIf (sss, colorYellow, colorRed ));


_SECTION_BEGIN("swing1");
no=20;
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();



_SECTION_BEGIN("trend");
uptrend=PDI(20)>MDI(10)AND Signal(29)<MACD(13);
downtrend=MDI(10)>PDI(20)AND Signal(29)>MACD(13);
Plot( 2, /* defines the height of the ribbon in percent of pane width */"ribbon", 
IIf( uptrend, colorGreen, IIf( downtrend, colorRed, 0 )), /* choose color */
styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_END();

Buy = s AND a AND uptrend ;
Short = ss AND b AND downtrend ;
Sell = ss AND b AND downtrend ;
Cover = s AND a AND uptrend ;

Buy=ExRem(Buy, Sell);
Sell=ExRem(Sell, Buy);
Cover=ExRem(Cover, Short);
Short=ExRem(Short, Cover);

Filter=Buy OR Sell;
Filter= Cover OR Short;

AddColumn( Buy, "Buy", 1);
AddColumn(Sell, "Sell", 1);
AddColumn(Close, "Close", 1.2);
AddColumn(Volume, "Volume", 1.0);


// Plot the Buy and Sell arrows.
shape = Buy * shapeUpArrow + Sell * shapeDownArrow;
PlotShapes(IIf(Buy, shapeSquare, shapeNone), colorGreen, 0, L, Offset=-10);
PlotShapes(IIf(Buy, shapeSquare, shapeNone), colorLime, 0, L, Offset=-20);
PlotShapes(IIf(Buy, shapeUpArrow, shapeNone), colorWhite, 0, L, Offset=-15);
PlotShapes(IIf(Sell, shapeSquare, shapeNone), colorRed, 0, H, Offset=20);
PlotShapes(IIf(Sell, shapeSquare, shapeNone), colorOrange, 0, H, Offset=30);
PlotShapes(IIf(Sell, shapeDownArrow, shapeNone), colorWhite, 0, H, Offset=-25);





//plot volume graph

// set background gradient colours
//SetChartBkGradientFill( ParamColor("BgTop", ColorRGB( 172, 172, 172 )), ParamColor("BgBottom", ColorRGB( 102, 136, 187 )), ParamColor("titleblock", ColorRGB( 255, 255, 255 )));
_SECTION_BEGIN("Raghee Horner's EMA's");
EMA1 = EMA(H, 34);
EMA2 = EMA(L, 34);
EMA3 = EMA(C, 34);

Plot( EMA1, "EMA1", ParamColor( "Color1", colorRed ), ParamStyle("Style", styleLine|styleThick) | styleNoRescale );
Plot( EMA2, "EMA2", ParamColor( "Color2", colorGreen ), ParamStyle("Style", styleLine|styleThick) | styleNoRescale );
Plot( EMA3, "EMA3", ParamColor( "Color3", colorBlue ), ParamStyle("Style", styleLine|styleThick) | styleNoRescale );
_SECTION_END();

_SECTION_BEGIN("Supertrend");
procedure calcTrend_proc(ATR_Period, tr, ATR_Multiplier, TrendMode, CalcPrice)
{
global buffer_line_down;
global buffer_line_up;
buffer_line_down = Null;
buffer_line_up = Null;

PHASE_NONE = 0;
PHASE_BUY = 1;
PHASE_SELL = -1;

phase=PHASE_NONE;
band_upper = 0;band_lower = 0;

for(i = ATR_Period + 1; i < BarCount; i++)
{
band_upper = CalcPrice[i] + ATR_Multiplier * tr[i];
band_lower = CalcPrice[i] - ATR_Multiplier * tr[i];

if(phase==PHASE_NONE)
{
buffer_line_up[i] = CalcPrice[i];
buffer_line_down[i] = CalcPrice[i];
}
if(phase!=PHASE_BUY && Close[i]>buffer_line_down[i-1] && !IsEmpty(buffer_line_down[i-1])) 
{
phase = PHASE_BUY;
buffer_line_up[i] = band_lower;
buffer_line_up[i-1] = buffer_line_down[i-1];
}
if(phase!=PHASE_SELL && Close[i]<buffer_line_up[i-1] && !IsEmpty(buffer_line_up[i-1]))
{
phase = PHASE_SELL;
buffer_line_down[i] = band_upper;
buffer_line_down[i-1] = buffer_line_up[i-1];
} 
if(phase==PHASE_BUY && ((TrendMode==0 && !IsEmpty(buffer_line_up[i-2])) || TrendMode==1) )
{
if(band_lower>buffer_line_up[i-1]) 
{
buffer_line_up[i] = band_lower;
}
else 
{
buffer_line_up[i] = buffer_line_up[i-1];
}
}
if(phase==PHASE_SELL && ((TrendMode==0 && !IsEmpty(buffer_line_down[i-2])) || TrendMode==1) )
{
if(band_upper<buffer_line_down[i-1])
{
buffer_line_down[i] = band_upper;
}
else
{
buffer_line_down[i] = buffer_line_down[i-1];
}
}
}
}

TrendMode = ParamToggle("TrendMode", "Off|On", 1);
ATR_Multiplier = Param("ATR_Multiplier", 2, 0.1, 10, 0.1);
ATR_Period = Param( "ATR_Period", 5, 1, 20, 1);
tr = ATR(ATR_Period);

CalcPrice = (H+L)/2;
calcTrend_proc(ATR_Period, tr, ATR_Multiplier, TrendMode, CalcPrice);

//Plot(buffer_line_up, "ntu", ColorRGB(28, 134, 238), styleThick);
//Plot(buffer_line_down, "ntd", ColorRGB(205, 51, 51), styleThick);

//Plot( 2, "", IIf(buffer_line_up, colorGreen, colorBlack), styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
//Plot( 4, "", IIf(buffer_line_down, colorRed, colorBlack), styleOwnScale|styleArea|styleNoLabel, -0.5, 100 );
_SECTION_END();
_SECTION_END();
 
#27
this is same from pastebin of shivangi by some parts, colors modified in it.
here only one kpl line is given, and many whipshaws are there - How to lessen them.

what is the strategy to trade with this system .
some more additions may be to add in the afl to get clear signal in chart and to avoid wrong signals & whipshaws.

one non related code I am searching for ami afl, where it can be available.
That is getting other timeframes kpl or nma lines(with different parameters each) in the same chart without changing time interval, along with the 5 min kpl line. like 15 min, 30 min, 60 min, 240 min like that all timeframes lines in one chart.
 
#28
this is same from pastebin of shivangi by some parts, colors modified in it.
here only one kpl line is given, and many whipshaws are there - How to lessen them.

what is the strategy to trade with this system .
some more additions may be to add in the afl to get clear signal in chart and to avoid wrong signals & whipshaws.

one non related code I am searching for ami afl, where it can be available.
That is getting other timeframes kpl or nma lines(with different parameters each) in the same chart without changing time interval, along with the 5 min kpl line. like 15 min, 30 min, 60 min, 240 min like that all timeframes lines in one chart.

***************
Hi Preethnfo,
Im looking for some thing similar, it would be easy to know the trend of 5min,15min,30min n 1hr trend in one single chart. I have various alfs downloaded from the internet. There are atleast one interesting stuffs in each afls, im trying to combine few selective ones and see how it works.. Will share once it is done..Im a new bee in coding but working with logics.. let see how this goes....If you already have this then hope you wudnt mind to share to save time and benifit others..
Cheers,
Nick
 

Similar threads