M 2 10 4
AA1:=(CLOSE-LLV(LOW,32))/(HHV(HIGH,32)-LLV(LOW,32))*1.2*CLOSE;
AA2:=SMA(AA1,13,1);
主力线:SMA(AA2,5.5,1.5),COLORCYAN;
股价线:3*AA2-2*主力线,COLORYELLOW;
散户线:4*主力线-3*AA2,COLORMAGENTA;
L1:=EMA(AA1,3);
L2:=EMA(AA1,5);
L3:=EMA(AA1,7);
STICKLINE(L1>L2,L3,L1,2,1),COLORRED;
STICKLINE(L1<L2,L3,L1,2,1),COLORGREEN;
T1:=L2>L3 AND L1<REF(L1,1);
T2:=L2<L3 AND L1>REF(L1,1);
STICKLINE(T1,L1,L3,2,0),COLORRED;
STICKLINE(T2,L1,L3,2,0),COLORGREEN;
RSVCC0:=(CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*100;
STICKLINE( RSVCC0>0, 100,0,10,0),COLORBLACK;
MA21:=EMA(C,20);
MA55:=EMA(C,55);
差20:=MA21-REF(MA21,1);
差55:=MA55-REF(MA55,1);
{20均线走平}
A2133:=REF(MA21,1);
A2200:=REF(MA21,2);
A2300:=REF(MA21,3);
AAAA2:=COUNT(MAX(MAX(MAX(MA21,A2133),A2200),A2300)-MIN(MIN(MIN(MA21,A2133),A2200),A2300)<=M/100,4)>=3;
走平20:=AAAA2 AND MA21>REF(MA21,1);
STICKLINE(走平20,0,1,2,0),COLORYELLOW;
{55均线走平}
A133:=REF(MA55,1);
A200:=REF(MA55,2);
A300:=REF(MA55,3);
AAAA:=COUNT(MAX(MAX(MAX(MA55,A133),A200),A300)-MIN(MIN(MIN(MA55,A133),A200),A300)<=M/100,4)>=3;
走平55:=AAAA AND MA55>REF(MA55,1);
STICKLINE(走平55,0,0.5,2,0),COLORRED;
{均线翻红}
均线翻红20:LONGCROSS(差20,0,9),COLORYELLOW;
持续关注:IF(LONGCROSS(差20,0,9),50,100),COLORGREEN,LINETHICK3;
买:DRAWICON(CROSS(股价线,主力线),主力线,27);
天下无敌:CROSS(股价线,主力线),COLORFFFF00;
趋势强弱:MA(100*(C-LLV(C,34))/(HHV(H,34)-LLV(L,34)),5)-20,COLORSTICK;
个股趋势:3*SMA((C-LLV(L,34))/(HHV(H,34)-LLV(L,34))*100,20,1)
-2*SMA(SMA((C-LLV(L,34))/(HHV(H,34)-LLV(L,34))*100,20,1),15,1),COLOR00DDDD,NODRAW;
大盘趋势:3*SMA((INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34))*100,20,1)
-2*SMA(SMA((INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34))*100,20,1),15,1),COLORDD22DD;
大盘危险:大盘趋势>80,COLOR00FF00,NODRAW;
大盘危险0:趋势强弱<0,,NODRAW;
个股危险:个股趋势>80,COLOR888888,NODRAW;
IF(1,大盘趋势,大盘趋势),COLORDD22DD;
IF(1,个股趋势,个股趋势),COLOR00DDDD;
持股:IF(个股趋势>REF(个股趋势,1) AND 大盘趋势>REF(大盘趋势,1),个股趋势,DRAWNULL),LINETHICK2,COLORRED;
预警:CROSS(大盘趋势,个股趋势) AND 个股趋势<3 OR LONGCROSS(个股趋势,0,3),COLORFF55FF,NODRAW;
STICKLINE(CROSS(大盘趋势,个股趋势)AND 个股趋势<3 OR LONGCROSS(个股趋势,0,3),0,20,1,0),COLORFF55FF;
地板价:IF(COUNT(个股趋势<0,3)=3 AND 个股趋势>REF(个股趋势,1),10,0),COLORFF6000,LINETHICK2;
RSVCC:=(CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*-100;
STICKLINE( RSVCC<0, 1-20,0,10,0),COLORBLACK;