以下是通达信波段持股副图指标源码(无源码的请下载附件导入)
VAR1:=EMA(CLOSE,8);
波段持股H1:VAR1,COLORFF00FF;
H2:EMA(VAR1,20),COLOR00FF00;
LH:EMA(CLOSE,240),COLORFFFFFF;
STICKLINE((VAR1>H2),VAR1,H2,0,0),COLORFFFF00;
STICKLINE((VAR1<H2),VAR1,H2,0,0),COLOR0000FF;
VAR2:=CROSS(VAR1,H2) AND ((VAR1<MA(CLOSE,120)) OR (VAR1<H2));
VAR3:=CROSS(VAR1,H2) AND (VAR1<EMA(CLOSE,120)) AND (COUNT(CLOSE,0)<120);
VAR4:=((HHV(HIGH,36)-CLOSE)/(HHV(HIGH,36)-LLV(LOW,36)))*(100);
VAR5:=SMA(VAR4,5,1);
VAR6:=SMA(VAR5,8,1);
VAR7:=CROSS(VAR5,VAR6) AND (VAR6<15);
VAR8:=(CLOSE>LLV(CLOSE,60)+(0.3)*(LLV(CLOSE,60))) AND VAR7;
VAR9:=IF((CLOSE>1000),VAR7,VAR8);
DRAWICON(VAR2,LOW-(LOW)*(0.01),1),COLOR008000;
DRAWICON(VAR3,LOW-(LOW)*(0.01),1),COLORFF0000;
DRAWICON(VAR9,HIGH+(HIGH)*(0.02),2),COLOR000080;
82344719.png
|