通达信MACD夹心指标公式
2020/6/4 18:14:27
SHORT:=12;
LONG:=26;
MID:=9;
DIFF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);
DEA:EMA(DIFF,MID);
MACD:(DIFF-DEA)*2,LINETHICK0;
STICKLINE(MACD>0,MACD,0,-1,1),COLORRED;
STICKLINE(MACD<0,MACD,0,-1,0),COLORCCCC00;
DRAWICON(ISLASTBAR=1 AND MACD>REF(MACD,1),HHV(MACD,42),1);
DRAWICON(ISLASTBAR=1 AND MACD<REF(MACD,1),HHV(MACD,42),2);
VAR1:=HHV(DEA,42);
VAR2:=LLV(DEA,42);
VAR3:=DEA-(DIFF-DEA);
VAR4:=DEA-(DIFF-DEA);
UP:IF(DIFF>VAR1 AND DEA=VAR1,MAX(LLV(VAR1,10),VAR3),VAR1),COLORBB9A00;
DN:IF(DIFF<VAR2 AND DEA=VAR2,MIN(HHV(VAR2,10),VAR4),VAR2),COLORAA00CC;
波↓:IF(DIFF<REF(DN,1),DIFF,DRAWNULL),COLOR00FF00,LINETHICK3;
波↑:IF(DIFF>REF(DN,1)AND DIFF<REF(UP,1),DEA,DRAWNULL),COLORFFFFFF,LINETHICK3;
☆DEA:IF(DIFF>REF(DN,1),DIFF,DRAWNULL),COLORFF00FF,LINETHICK3;
看 股吧公式 www.ka nguba.com
其它股票公式列表