通达信买时机选股副图公式 源码
STICKLINE(C>0,0,100,100,0),COLOR781816;
VAR1:=(HHV(HIGH,5)-LLV(LOW,5));
VAR2:=(HHV(HIGH,9)-CLOSE);
VAR3:=(CLOSE-LLV(LOW,9));
VAR4:=VAR2/VAR1*100-70 ;
VAR5:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*100;
VAR6:=(2*C+H+L)/4;
VAR7:=SMA((VAR3/VAR1*100),3,1);
VAR8:=LLV(LOW,34);
VAR9:=SMA(VAR7,3,1)-SMA(VAR4,9,1);
VAR10:= IF(VAR9>100,VAR9-100,0);
VARA:=HHV(HIGH,34);
主力: 3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)-2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1),LINETHICK2;
防线:EMA((VAR6-VAR8)/(VARA-VAR8)*100,8),COLORFF00FF;
B1:=EMA(防线,5);
买入时机: IF(CROSS(主力,10),30,10),LINETHICK2,COLORRED ;
卖出时机: IF(CROSS(90,主力),70,90),LINETHICK2,COLORGREEN ;
STICKLINE(防线>0 AND 防线-B1>=0,49,50,6,0),COLORGREEN;
STICKLINE(防线>0 AND 防线-B1<0,49,50,6,0),COLORRED;
DRAWICON(CROSS(主力,10),32,23);
DRAWICON(CROSS(90,主力),67,15);
DRAWICON((主力>50 AND 防线>50 AND (CROSS(主力,防线))),(主力-2),25);
选
源码:
VAR6:=(2*C+H+L)/4;
VAR8:=LLV(LOW,34);
VARA:=HHV(HIGH,34);
防线:=EMA((VAR6-VAR8)/(VARA-VAR8)*100,8);
B1:=EMA(防线,5);
防线>0 AND 防线-B1<0;