在线检测未来函数

通达信MACD日周月指标公式

来源:Internet,编辑:股旁网,2023-03-14

月DIF:"macd.DIF#MONTH"COLORMAGENTA,DOTLINE;
月DEA:"MACD.DEA#MONTH"COLORGREEN,DOTLINE;
周DIF:"MACD.DIF#WEEK";
周DEA:"MACD.DEA#WEEK";
STICKLINE(月DIF>月DEA AND 月DEA<0 AND 月DIF<0 AND {周DIF>=REF(周DIF,5) AND} Abs(月DIF)<ABS(月DEA-月DIF),月DIF,0,4,0 ),COLORCCCCCC;
DRAWBAND(月DIF,RGB(110,50,0),月DEA,RGB(0,160,50));
DRAWBAND(周DIF,RGB(180,160,221),周DEA,RGB(10,100,100));
{萎缩:=(周DIF-周DEA)<=(REF(周DIF,5)-REF(周DEA,5)) AND 周DIF>周DEA;
萎缩1:=(月DIF-月DEA)<=(REF(月DIF,20)-REF(月DEA,20)) AND 月DIF>月DEA;
DRAWICON(萎缩,周DIF,2);
DRAWICON(萎缩1,月DIF,2);}
月条件:=月DIF>0 AND 月DEA<0.15 AND 周DIF>=REF(周DIF,5);
周条件:=周DIF>0 AND 周DEA<0 AND 月DIF>月DEA AND 周DIF>=REF(周DIF,5) AND REF(周DIF,5)>=REF(周DIF,10) AND ABS(月DIF)-ABS(周DEA)<0.7 AND 周DEA>=月DIF;
NOTEXTDIFF1:=EMA(CLOSE,12)-EMA(CLOSE,26);
NOTEXTDEA1:=EMA(NOTEXTDIFF1,9);
DIF:EMA(CLOSE,12)-EMA(CLOSE,26),COLORRED;
DEA:EMA(DIF,9),COLORLIBLUE;
MACD:2*(DIF-DEA),COLORSTICK;
DRAWBAND((DIF>REF(DIF,1) AND DIF>0 AND DEA>0 AND DIF>DEA AND MACD>DIF AND MACD>=REF(MACD,1))*ABS(MACD),RGB(200,0,0),0,RGB(200,0,0));
DRAWICON(月条件,月DIF,42);
DRAWICON(周条件,周DIF,11);
A2:=BARSLAST(REF(crOSS(DEA,DIF),1));
顶背离:=REF(CLOSE,A2+1)<CLOSE AND REF(DIF,A2+1)>DIF AND CROSS(DEA,DIF);
顶背:DRAWLINE(A2=0,DEA,顶背离,DEA,0),COLORGREEN,LINETHICK4;
DRAWICON(顶背离,DEA,2);

通达信MACD日周月指标公式

相关文章