FILTER IS 14 PERIOD ADX ABOVE 30
UPTREND = 1 MEANS YOUR UPTREND CONDITION
DOWNTREND = 1 MEANS YOUR DOWNTREND CONDITION
IF BOTH ARE ZEROS MEANS ONLY 14 PERIOD ADX ABOVE 30 IS SATISFIED
HERE PR = PERIOD OF ADX SO IF YOU WANT TO CHANG YOU CAN CHANGE THE PR VALUE
AV IS ADX VALUE.SO YOU CAN CHANE AV FOR ADJUSTING ADX VALUE
AV =30;
PR = 14;
A = PDI(PR) < 20 ;
B = MDI(PR) < 20 ;
E = ADX(PR) > AV;
P = PDI(PR) ;
Q = MDI(PR);
HL = P > Q;
LH = Q > P;
F = ADX(PR);
X = E AND HL AND B ;
Y = (E == 1)AND (LH ==1) AND (A ==1) ;
//Filter = (X== 1) OR (Y == 1);
Filter = E == 1;
//AddColumn(HI,"H",1,colorDefault );
//AddColumn(LW,"L",1,colorDefault);
AddColumn(F,"14PERIOD",1.2,colorWhite,colorBlue);
AddColumn(X,"UPTREND",1.2,colorWhite,colorDarkGreen);
AddColumn(Y,"DOWNTREND",1.2,colorWhite,colorRed);
AddColumn(P,"POSITIVE",1.2,colorWhite,colorGreen);
AddColumn(Q,"NEGATIVE",1.2,colorWhite,colorRed);
AddColumn(Close,"Close",1.2);
AddColumn(ROC(Close,1),"%change",1.2,colorWhite,IIf(ROC(C,1)>0,colorGreen,IIf(ROC(C,1)<0,colorRed,colorOrange)));
AddColumn(Volume,"Volume",1.0);
AddColumn(MA(Volume,20),"TB20 Vol",1.2);
👉Tải tại đây
https://drive.google.com/file/d/1aij9tAypD1g3EtVdIK-3OfTw0HQDw42v/view?usp=drive_link
Cách sử dụng AFL cho Amibroker
Tải xuống tệp Amibroker AFL.
Bây giờ hãy sao chép tệp afl và dán vào vị trí cài Amibroker
D:\A KY PC\Win\Amibroker\Formulas\VIP free
Hữu ích !
ReplyDelete