DIFF : EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);
DEA
MACD : 2*(DIFF-DEA), COLORSTICK;
JC := DEA-DIFF;
綠柱面積:=IF(MACD<0,SUM(MACD,BARSLAST(JC<0)),0);
紅柱面積:=IF(MACD>0,SUM(MACD,BARSLAST(JC>0)),0);
本次最低價(jià):=LLV(L,BARSLAST(JC<0));
本次最高價(jià):=HHV(H,BARSLAST(JC>0));
X1:=IF (MACD<0,BARSLAST(CROSS(DIFF,DEA)),0);
前次綠柱面積:=REF(綠柱面積,X1+1);
前次最低價(jià):=REF(本次最低價(jià),X1+1);
Y1:=IF((綠柱面積<0 AND ABS(綠柱面積)<ABS(前次綠柱面積)
AND 本次最低價(jià)<前次最低價(jià) ),1,0);
RS1:= MACD<0 AND REF(MACD,1)<0 AND C<前次最低價(jià)
AND ABS(綠柱面積)<ABS(前次綠柱面積) AND ABS(MACD)<ABS(REF(MACD,1));
底背馳:= IF (CROSS(DIFF,DEA),REF(Y1,1),0);
DRAWTEXT(底背馳,0.3,'積底背'),COLOR00FFFF;
STICKLINE(底背馳,0,0.3,4,0),COLOR0000FF;
DRAWICON(底背馳,0,23),COLORYELLOW;
DRAWBAND(DIFF,RGB(200,50,55),DEA,RGB(50,100,10));
遵:IF(DIFF>=DEA,DIFF,DRAWNULL),COLORRED;
守:IF(DEA>=DIFF,DEA,DRAWNULL),COLORFF9900;
紀(jì):IF(DIFF>=DEA,DEA,DRAWNULL),COLOR00FFFF;
律:IF(DEA>=DIFF,DIFF,DRAWNULL),COLOR00FF00;
X2:=IF (MACD>0,BARSLAST(CROSS(DEA,DIFF)),0);
前次紅柱面積:=REF(紅柱面積,X2+1);
前次最高價(jià):=REF(本次最高價(jià),X2+1);
Y2:=IF((紅柱面積>0 AND 紅柱面積<前次紅柱面積 AND 本次最高價(jià)>前次最高價(jià) ),1,0);
RS2:= MACD>0 AND REF(MACD,1)>0 AND C>前次最高價(jià) AND ABS(紅柱面積)<ABS(前次紅柱面積) AND ABS(MACD)<ABS(REF(MACD,1));
頂背馳:= IF (CROSS(DEA,DIFF),REF(Y2,1),0);
DRAWICON(頂背馳,0,19),COLOR00FF00;
STICKLINE(頂背馳,0,-0.3,4,0),COLOR00FF00;
DRAWTEXT(頂背馳,-0.3,'積頂背'),COLORFF0000;
short
long
m
聯(lián)系客服