通达信一品老师的高山流水公式(叠加波段,效果非常好)
DIFF1:=EMA(C,3) - EMA(C,13);
DEA1 :=EMA(DIFF1,9);
MACD1:=2*(DIFF1-DEA1){*10};
DIFF2:=EMA(C,5) - EMA(C,26);
DEA2 :=EMA(DIFF2,9);
MACD2:=2*(DIFF2-DEA2){*10};
DIFF3:=EMA(C,7) - EMA(C,89);
DEA3 :=EMA(DIFF3,21);
MACD3:=2*(DIFF3-DEA3){*10};
AAAA:=CONST(HHV(H,450));
BBBB:=CONST(LLV(L,450));
AB:=(AAAA+BBBB)/2;
STICKLINE(C>0,AB,AAAA,6,0),COLORE5C3EA;
STICKLINE(C>0,AB,BBBB,6,0),COLORF6B06C;
STICKLINE(MACD3>=0,AB,MACD3+AB,5,0),COLOR009E3A;
STICKLINE(MACD3<0,AB,-MACD3+AB,5,0),COLOR646464;
STICKLINE(MACD2>=0,AB,MACD2+AB,5,0),COLOR007D19;
STICKLINE(MACD2<0,AB,-MACD2+AB,5,0),COLOR555555;
STICKLINE(MACD1>=0,AB,MACD1+AB,5,0),COLOR006400;
STICKLINE(MACD1<0,AB,-MACD1+AB,5,0),COLOR414141;
STICKLINE(MACD3,AB,-ABS(MACD3)*0.6+AB,5,0),COLOR232323;
STICKLINE(MACD1,AB,-ABS(MACD1)*0.6+AB,5,0),COLOR0F0F0F;
DRAWKLINE(HIGH,OPEN,LOW,CLOSE);
高山:HHV(MA(H,N),N),COLORRED,LINETHICK2;
流水:MA(H,N),COLORFFFFFF,LINETHICK2;
出水:IF(C>HHV(MA(H,N),8) AND HHV(MA(H,N),8)>MA(H,N),1,DRAWNULL),COLORFF00FF,POINTDOT,NODRAW;
回踩:IF((CROSS(MA(H,N),L) OR CROSS(MA(H,N)*1.01,C))AND BARSLAST(出水)<=5,1,DRAWNULL),COLOR00FFFF,POINTDOT,NODRAW;
STICKLINE(出水,(C+O)/2,(C+O)/2,3,0),COLORFF00FF;{公式在线提供:www.gszx.com.cn}
STICKLINE(出水,H,L,0,0),COLORFF00FF;
DRAWTEXT(回踩,L, '↑'),COLORFFFFFF;
HHV(流水,2),COLOR00FF00;
HHV(流水,3),COLOR00FF00;
HHV(流水,4),COLOR00FF00;
HHV(流水,5),COLOR00FF00;
HHV(流水,6),COLOR00FF00;
HHV(流水,7),COLOR00FF00;
HHV(流水,8),COLOR00FF00;
HHV(MA(H,N),N),COLORRED,LINETHICK2;