N:=13;
M:=5;
VAR1:=VOL*(O+C)/2;
生命线:SUM(VAR1,88)/SUM(VOL,88),COLORFF80FF,LINETHICK2;
持股线FL:HHV(MA(C,17),2),COLOR00D500;
FS:IF(MA(C,17)<持股线FL,(MA(C,17)-(持股线FL-MA(C,17))),持股线FL),COLOR80FFFF,LINETHICK2;
CG:MA(C,17),LINETHICK2,COLORF4E202;
VAR2:=MA((OPEN+CLOSE+HIGH+LOW)/4,46);
AA:=(CLOSE>VAR2 AND CLOSE>MA(CLOSE, 5)) OR (C<VAR2 AND C>MA(C,5) AND C>FS);
BB:=(CLOSE<VAR2 AND C<MA(C,5)) OR (C>VAR2 AND C<MA(C,5));
CC:=IF(AA AND BB,0,1);
STICKLINE(CC,CLOSE,OPEN,6,1),COLORYELLOW;
STICKLINE(CC,HIGH,MAX(C,O),0.8,0),COLORYELLOW;
STICKLINE(CC,MIN(C,O),LOW,0.8,0),COLORYELLOW;
STICKLINE(AA,CLOSE,OPEN,6,0),COLORRED;
STICKLINE(AA,HIGH,LOW,0.8,0),COLORRED;
STICKLINE(BB,CLOSE,OPEN,6,0),ColorFFFF00;
STICKLINE(BB,HIGH,LOW,0.8,0),ColorFFFF00;
A1:=CLOSE>MA(CLOSE,N);
A2:=CLOSE>MA(CLOSE,M) AND CLOSE<MA(CLOSE,N);
STICKLINE(A1=1,O,C,-1,1),COLORRED,LINETHICK2;
STICKLINE(A1=1,L,H,0,0),COLORRED,LINETHICK2;
STICKLINE(A2=1,O,C,-1,1),COLORYELLOW,LINETHICK5;
STICKLINE(A2=1,L,H,0,0),COLORYELLOW,LINETHICK5;
RSV:=(CLOSE-LLV(LOW,25))/(HHV(HIGH,25)-LLV(LOW,25))*100;
K:=SMA(RSV,3,1);
D1:=SMA(K,3,1);
J:=3*K-2*D1;
VAR3:=(2*CLOSE+HIGH+LOW)/3;{可将3该为4,信号少点}
VAR4:=EMA(EMA(EMA(VAR3,4),4),4);{可将3该为4,信号少点}
E:=(VAR4-REF(VAR4,1))/REF(VAR4,1)*100;
F:=MA(E,3)+0.03;
G:=MA(E,1);
DRAWICON(CROSS(F,G) AND J>65,HIGH*1.02,5),COLORGREEN;
///////////////////////////////////////////////////////
买值:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
KK:=SMA(买值,3,1);
DD:=SMA(KK,3,1);
JJ:=3*KK-2*DD;
X:=LLV(JJ,2)=LLV(JJ,8);
Y:=IF(CROSS(J,REF(JJ+0.01,1)) AND X AND JJ<20,30,0);
主力:=EMA( (CLOSE-MA(CLOSE,3))/MA(CLOSE,3),2);
散户:=EMA( (CLOSE-MA(CLOSE,20))/MA(CLOSE,20),7);
VAR1:=LLV(LOW,10);
VAR2:=HHV(HIGH,25);
动能趋势线:=100*EMA((CLOSE-VAR1)/(VAR2-VAR1),4);
DRAWTEXT(CROSS(动能趋势线,70),HIGH*1.02,'险'),COLORGREEN;
DRAWTEXT(CROSS(动能趋势线,80),HIGH*1.02,'减'),COLOR00FF00;
DRAWTEXT(CROSS(动能趋势线,87.5),HIGH*1.02,'出局'),COLORWHITE;
DRAWTEXT(CROSS(JJ,REF(JJ+0.01,1)) AND X AND JJ<20,LOW,'短进'),COLORFF00FF;
DRAWTEXT(CROSS(主力,散户) AND 主力<0 AND 散户<0,LOW,'见底'),COLORRED;
DRAWICON(CROSS(主力,散户) AND 主力<0 AND 散户<0,LOW,4);
VAR5:=REF(CLOSE,1);
VAR6:=SMA(MAX(CLOSE-VAR5,0),6,1)/SMA(ABS(CLOSE-VAR5),6,1)*100;
DRAWTEXT(CROSS(84,VAR6),H*1.03,'逃顶'),COLORYELLOW ;
202108211127.jpg
|