通达信为了正义主图指标公式
通达信最低对子选股指标公式
通达信为了正义主图指标公式:
G:=5;
中线:(EMA(C,30)+EMA(C,72))/2,COLORCYAN;
{顶线:中线+中线*0.80,COLORCYAN;}
铁底:中线-中线*0.49,COLORMAGENTA;
顶线:中线+中线*0.22,COLORRED;
极底:中线-中线*0.29,COLORRED;
VAR1X:=zig(3,10)<REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)>REF(ZIG(3,10),2);
VAR2X:=ZIG(3,10)>REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)<REF(ZIG(3,10),2);
VAR9:=IF(YEAR > 2110,0,VAR1X);
VAR10:=IF(YEAR > 2110,0,VAR2X);
stICKLINE(VAR9,H*1.02,H,10,0),COLORYELLOW,LINETHICK2;
STICKLINE(VAR10,L*0.96,L*0.91,10,0),COLORRED,LINETHICK2;
MA5:MA(CLOSE,5),COLORYELLOW;
MA10:MA(CLOSE,10),COLORBLUE;
MA20:MA(CLOSE,20),COLORRED;
MA30:MA(CLOSE,30),COLORGREEN;
MA60:MA(CLOSE,60),COLORLIRED;
MA99:MA(CLOSE,99),COLORWHITE;
R:=0.2;
R1:=0.1;
底线:中线-中线*R,COLORCYAN;
P:=55;S:=8;M1:=3;
财:=(EMA(CLOSE,S)-EMA(CLOSE,P))*10,COLORRED,LINETHICK2;
神:=EMA(财,M1),COLORGREEN,LINETHICK1;
VAR1:=EMA(EMA(CLOSE,13),13);
控盘:=(VAR1-REF(VAR1,1))/REF(VAR1,1)*1000;
BTJ2:=控盘>REF(控盘,1) AND 控盘<-0.2;
BTJ3:=crOSS(财,神) AND 财<-0.3;
JJ:=DYNAINFO(11);
BTJ11:=(C-JJ)/JJ<-0.03;
BTJ811:=FILTER(BTJ11 AND BTJ2 AND BTJ3,13);
庄:= BTJ11 AND BTJ2 AND BTJ3;
有庄:=FILTER(庄,55),COLORWHITE;
DRAWTEXT(BTJ811,H*1.4,'庄进'),COLORRED;
STICKLINE(BTJ811,H,H*1.35,0,0),COLORBLUE;
D:=MA(CLOSE,80)-MA(CLOSE,10)/3;
CD:=CLOSE<D AND vol/240>MA(VOL,5)/240 AND CLOSE>REF(CLOSE,1)*0.99
AND CLOSE<MA(CLOSE,13)*1.3;
DRAWTEXT(IF(CD,1,0),H*1.35,'抄底'),COLORRED;
STICKLINE(CD,H,H*1.35,0,0),COLORRED;
STICKLINE(CD,L,H,0,0),COLOR0088EE;
A1:=(3*C+L+O+H)/6;
A2:=LLV(LOW,34);
A3:=HHV(HIGH,34);
A4:=(INDEXC-HHV(INDEXC,8))/HHV(INDEXC,8)<-0.05 AND MA(INDEXA,125)/MA(INDEXV,125)/(MA(INDEXA,5)/MA(INDEXV,5))>1.11;
A5:=EMA((A1-A2)/(A3-A2)*A3,7);
A6:=CROSS(A5,MA(A5,7));
A8:=BArslAST(A4)<13;
ZCQYL:=MA(A3,3);
HD:=EMA(A1,89)*0.74;
HPM:=EMA(A1,89)*0.84;
TPZCQYL:=FILTER((C>ZCQYL*0.97 AND (V/REF(V,1)>1.03) AND C>REF(C,1)),5);
Q1:=A6 AND C<=HD AND A8;
Q2:=REF(C,1)<HD AND C>O AND C>HD*0.97;
Q3:=REF(C,1)<HD AND C>O AND C<HD*1.03;
Q4:=TPZCQYL AND C<=HPM*1.03;
DRAWTEXT(FILTER(Q1 OR Q2 OR Q3 OR Q4,5),L*0.97,'不全买'),COLORYELLOW;
QSXS:=MA20>MA30 AND MA20>REF(MA20,1) AND MA30>REF(MA30,1);
ZF:=(C/REF(C,1)-1)*100;
N1:=BARSLAST(CROSS(C,MA(C,5)));
N2:=BARSLAST(CROSS(MA(C,5),C));
HM:=IF(N1<N2,N1+1,0)*QSXS;
Z2:=HM=1 AND ZF>=0 AND C>O AND QSXS;
KX1:=ZF<=-3 AND C<O;
XDSJ:=BARSLAST(KX1);
KX2:=ZF>=3 AND C>O;
JBY:=KX2 AND XDSJ<=2 AND C>=REF(O*0.99,XDSJ) AND ZF>Abs(REF(ZF,XDSJ)*0.99);
Z3:=IF(FILTER(JBY,1) AND QSXS,5,0);
QTY:=Z2 AND Z3;
DRAWTEXT(QTY,H*1.02,'追涨'),COLORYELLOW;
VAR326:=IF(CLOSE>REF(CLOSE,1),88,0);
VAR327:=IF(CLOSE/REF(CLOSE,1)>1.050 AND HIGH/CLOSE<1.010 AND VAR326>0, 91, 0);
DRAWTEXT(VAR327>90,LOW*0.85,'追吧'),COLORYELLOW;
{绝密买点}
A81:=EMA(C,3),COLORWHITE;
A82:=EMA(C,5),COLORYELLOW;
A83:=EMA(C,7),COLORMAGENTA;
A84:=EMA(C,12),COLORGREEN;
A85:=EMA(C,20),COLORRED;
A86:=EMA(C,50),COLORBLUE,LINETHICK2;
SS8:=CROSS(A81,A85) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018 ;
SSS8:=CROSS(A81,A85) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018;
STICKLINE(SS8,CLOSE,OPEN,0,0),COLORGREEN;
DRAWTEXT(SS8,L-0.78,'少买点'),COLORYELLOW;
CB80:=EMA(((COST(99.3)+COST(70.7))/2+COST(85))/2,13);
CB66:=EMA(((COST(99)+COST(33))/2+COST(66))/2,13);
CB:=EMA((((COST(80.9)+COST(19.1))/2+(COST(61.8)+COST(38.2))/2)/2+COST(50))/2,13);
CB6:=EMA(((COST(6)+COST(16))/2+COST(11))/2,13);
UPDOWN:=IF((C-CB6)<0,1,0);
MacB80:=MA(CB80,13);
MACB66:=MA(CB66,13);
MACB:=MA(CB,13);
MACB6:=MA(CB6,13);
MA向上:=IF((MACB80>REF(MACB80,5) OR MACB66>REF(MACB66,5) OR MACB>REF(MACB,5)) OR MACB6>REF(MACB6,5),1,0);
主力建仓:=IF(C>CB6 AND SUM(UPDOWN,220)>20 AND (C/HHV(C,700)<0.5 OR C/LLV(C,700)<1.7) AND MA向上,SUM(UPDOWN,220),0);
卧龙式盘建仓:=IF(主力建仓>0 AND SUM(主力建仓,400)>88,SUM(主力建仓,400),0);
刘备捞月式建仓:=IF(主力建仓 AND C/HHV(C,700)<0.35,SUM(UPDOWN,220),0);
三顾茅庐:=IF(主力建仓>0 AND 卧龙式盘建仓>0 AND 刘备捞月式建仓>0,(主力建仓+卧龙式盘建仓+刘备捞月式建仓)/3,0);
STICKLINE(三顾茅庐>0,CB6*0.98,CB6*1.0,7,0),COLORBLUE;
WLT1:=EMA(C,3);
TEND:=EMA(((SLOPE(CLOSE,21) * 20) + CLOSE),42);
WL2:=CROSS(WLT1,TEND);
WL8:=LLV(LOW,34);
DRAWTEXT(WL2 AND C>TEND AND C<WL8*1.3,LOW*0.96,'全仓'),COLORLIBLUE;
A007:=(HIGH+LOW+CLOSE)/3;
A008:=((A007-MA(A007,14))/(0.015*AVEDEV(A007,14)))/2;
A009:=(A008+(EMA(((0-(100*(HHV(HIGH,14)-CLOSE)/(HHV(HIGH,14)-LLV(LOW,14))))+100)/100,3)*200-100))/2;
A010:=A009-REF(A009,14);
A011:=A009-REF(A009,26);
A012:=(A009+A010+A011)/3;
KKM:=EMA(A012,4);
DRAWTEXT(FILTER(KKM>EMA(KKM,4) AND KKM>REF(KKM,1),30),L*0.98,'快速'),COLORYELLOW;
XL1:=((LLV(LOW,3) = LLV(LOW,60)) AND ((CLOSE / REF(CLOSE,1)) >= 1.04));
DM:=FILTER(((XL1 > 0) AND LOW),5);
DRAWTEXT(DM,(L*0.79),'多买点');
STICKLINE(DM,L,L*0.79,0,0),COLORWHITE;
STICKLINE(DM,CLOSE,OPEN,0,0),COLORRED;
{短线爆涨};
MA6:=MA(C,6);
A2Q:=REF(MA20,1);
J1:=(MA20-A2Q)/A2Q*100;
MJ1:=MA(J1,3);
MA120:=MA(C,120);
乖离2:=(MA20-MA30)/MA30*100;
VAR1Q:=IF(BETWEEN(乖离2,-2,5),2,0);
MAX1:=MAX(MA20,MA30);
MAX2:=MAX(MAX1,MA60);
MINN1:=MIN(MA20,MA30);
MIN2:=MIN(MINN1,MA60);
K1:=(MAX2/MIN2-1)*100;{粘合度符合条件}
VAR2Q:=IF(K1<=8,1,0);
短线暴涨:DRAWTEXT(FILTER( (VAR1Q OR VAR2Q) AND MA10>REF(MA10,1) AND COUNT(MA30>REF(MA30,1),3)=3 AND MA30>MA60 AND COUNT(CROSS(MA5,MA30),3) AND J1>MJ1 AND MA(V,5)>MA(V,60)
AND MA(V,60)>REF(MA(V,60),1),5),MA60*0.99,'短线暴涨'),COLORRED;
{清仓}
AA05:=MA(C,5);
AA13:=MA(C,13);
AA34:=MA(C,34);
AACP:=dkx;
五日乖离率:=(C-AA05)/AA05*100;
BB05:=ATAN((AA05/REF(AA05,1)-1)*100)*180/3.1416;
BB34:=ATAN((AA34/REF(AA34,1)-1)*100)*180/3.1416;
BBCP:=ATAN((AACP/REF(AACP,1)-1)*100)*180/3.1416;
速度5:=SMA(EMA((AA05-REF(AA05,1))/REF(AA05,1),3)*100,3,1);
加速度5:=EMA((速度5-REF(速度5,1)),3);
三拾日乖离率:=(C-AA34)/AA34*100;
强势狙击:=FILTER(BB34>30 AND BBCP>45 AND CROSS(BB05,60),10);
加仓:=FILTER(COUNT(CROSS(BB05,30),5)>=1 AND AA05>REF(AA05,1) AND 三拾日乖离率>REF(三拾日乖离率,1) AND AA13>REF(AA13,1)
AND 加速度5>REF(加速度5,1) AND 速度5>REF(速度5,1) ,10) ;
清仓:=FILTER(COUNT(CROSS(30,BB05),5)>=1 AND (C>AA34 OR O>AA34) AND AA05<REF(AA05,1) AND 三拾日乖离率<REF(三拾日乖离率,1) AND AA13<REF(AA13,1),10);
DRAWTEXT(加仓 ,LOW*1.18,'加仓'),COLORRED;
JC:=CROSS(0,五日乖离率) AND 三拾日乖离率<REF(三拾日乖离率,1) AND AA13>REF(AA13,1) ;
减仓:=FILTER(JC,10);
MR:=COUNT(CROSS(五日乖离率,0),3)>=1 AND 三拾日乖离率>REF(三拾日乖离率,1) AND AA05>REF(AA05,1) AND (C/REF(C,1)-1)*100>5 AND REF(C,1)<AA34;
买入:=FILTER(MR,10);
DRAWTEXT(减仓,HIGH*1.02,'减仓'),COLORCYAN;
DRAWTEXT(买入,H,'买入'),COLORRED;
DRAWTEXT(清仓 ,HIGH*1.02,'清仓'),COLORGREEN;
{VAR3AA:=IF((CLOSE>REF(CLOSE,1)),88,0);
VAR4AA:=IF(((CLOSE)/(REF(CLOSE,1))>1.05) AND ((HIGH)/(CLOSE)<1.01) AND (VAR3AA>0),91,0);
DRAWTEXT(FILTER((VAR4AA>90),45),(LOW)*(0.93),'大胆搏 '),COLOR00FFFF;}
VARFN:=LOW*0.9;
VAR11N:=EMA(VARFN,30);
VAR12N:=CLOSE-REF(CLOSE,1);
VAR13N:=MAX(VAR12N,0);
VAR14N:=ABS(VAR12N);
VAR15N:=SMA(VAR13N,7,1)/SMA(VAR14N,7,1)*100;
VAR16N:=SMA(VAR13N,13,1)/SMA(VAR14N,13,1)*100;
VAR17N:=BARSCOUNT(CLOSE);
VAR18N:=SMA(MAX(VAR12N,0),6,1)/SMA(ABS(VAR12N),6,1)*100;
VAR19N:=(-200)*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60))+100;
VAR1AN:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
VAR1BN:=SMA((SMA(VAR1AN,4,1)-50)*2,3,1);
VAR1CN:=(INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14))*100;
VAR1DN:=SMA(VAR1CN,4,1);
VAR1EN:=SMA(VAR1DN,3,1);
VAR1FN:=(HHV(HIGH,30)-CLOSE)/CLOSE*100;
VAR20N:=VAR18N<=25 AND VAR19N<-95 AND VAR1FN>20 AND VAR1BN<-30 AND VAR1EN<30
AND VAR11N-CLOSE>=-0.25 AND VAR15N<22 AND VAR16N<28 AND VAR17N>50;
QL:=VAR20N;
DRAWTEXT(QL,H*1.05,'青'),LINETHICK1,COLORGREEN;
STICKLINE(QL,H,H*1.05,0,0),COLORGREEN;
VARF8:=(2*CLOSE+HIGH+LOW)/4;
VAR108:=LLV(LOW,34);
VAR118:=HHV(HIGH,34);
VAR128:=EMA((VARF8-VAR108)/(VAR118-VAR108)*100,6);
VAR138:=EMA(0.667*REF(VAR128,1)+0.333*VAR128,4);
DRAWTEXT(IF(COUNT(CLOSE<REF(CLOSE,1),8)/8>0.3 AND COUNT(VAR128>VAR138,3) AND REF(LOW,1)=LLV(LOW,120) AND CLOSE>OPEN,1,0),L*0.85,'机构进场'),COLORRED;
{适当建仓}
MID:=MA(CLOSE,21),COLORWHITE;
单边上升:=(C>MID);
多头行情:=C>MA(C,5) AND MA(C,5)>MA(C,10);
LOOW:=MID - 2.58*STD(CLOSE,21),COLORFF00FF;
适当建仓:=(单边上升 AND FILTER(多头行情,20) AND V>MA(V,3));
DRAWTEXT(适当建仓,LOOW,'适当建仓'),COLORRED;
STICKLINE(适当建仓,L,LOOW,0,0),COLORRED;
UPPER:=MID + 1.96*STD(CLOSE,21),COLORYELLOW;
布林线缩口:=((UPPER-MID)/MID<0.05);
股价在低位:=((C-LLV(C,30))/(HHV(C,30)-LLV(C,30))<0.4);
一波行情起:=(BARSLAST(布林线缩口)<=3 AND V>MA(V,3) AND 股价在低位 AND C>REF(C,1) AND C>MA(C,10));
LOWER:=MID - 1.96*STD(CLOSE,21),COLORYELLOW;
DRAWTEXT(FILTER(一波行情起,5),LOWER,'一波行情起'),COLORRED;
{最佳买入}
{LC2:=REF(CLOSE,1);
rsi52:=((SMA(MAX((CLOSE - LC2),0),5,1) / SMA(ABS((CLOSE - LC2)),5,1)) * 100);
TR12:=SUM(MAX(MAX((HIGH - LOW),ABS((HIGH - REF(CLOSE,1)))),ABS((LOW - REF(CLOSE,1)))),10);
HD2:=(HIGH - REF(HIGH,1));
LD2:=(REF(LOW,1) - LOW);
DMP2:=SUM(IF(((HD2 > 0) AND (HD2 > LD2)),HD2,0),10);
DMM2:=SUM(IF(((LD2 > 0) AND (LD2 > HD2)),LD2,0),10);
pdi2:=((DMP2 * 100) / TR12);
mdi2:=((DMM2 * 100) / TR12);
ADX2:=MA(((ABS((MDI2 - PDI2)) / (MDI2 + PDI2)) * 100),5);
AV2:=(RSI52 + ADX2);
DXR2:=(((ADX2 + REF(ADX2,5)) / 2) + RSI52);
wr102:=((100 * (HHV(HIGH,10) - CLOSE)) / (HHV(HIGH,10) - LLV(LOW,10)));
NEWVOL2:=(RSI52 - WR102);
最佳买入2:=(AV2 + NEWVOL2);
DRAWTEXT(CROSS(最佳买入2,0),L*0.90,'最佳买入'),COLOR00FFFF;
STICKLINE(CROSS(最佳买入2,0),L,L*0.90,0.1,0),COLORYELLOW;}
{底背M}
SQX:=(C-MA(CLOSE,13))*10;
DIF:=EMA(MA(SQX,7),1);
DEA:=EMA(DIF,7);
A11:=BARSLAST(REF(CROSS(DIF,DEA),1));
B1:=REF(C,A11+1)>C AND REF(DIF,A11+1)<DIF AND CROSS(DIF,DEA);
DRAWTEXT(B1>0,L*0.80,'M底背'),COLORRED;
STICKLINE(B1>0,L,L*0.80,0.1,0),COLORRED;
{斋主全仓}
AA:=(MA(C,1)+MA(C,3)+MA(C,5)+MA(C,7)+MA(C,9))/5;
BB:=(MA(C,2)+MA(C,4)+MA(C,6)+MA(C,8)+MA(C,10))/5;
CC:=EMA(AA,2);
DD:=EMA(BB,5);
TJ0:=CROSS(CC,DD);
上:=EMA(C,3);
中:=EMA(C,5);
下:=EMA(中,5);
TJ1:=CROSS(上,中);
TJ2:=上>REF(上,1);
X1:=(C+L+H)/3;
BB5:=ATAN(EMA(X1,5)-REF(EMA(X1,5),1))*3.1416*10;
EMA3:=EMA(C,3);
TJ3:=BB5>1 AND EMA(X1,5)>REF(EMA(X1,3),1);
DRAWTEXT(TJ1 AND TJ2 AND TJ0 AND TJ3,H*1.19,'群主全仓'),COLORRED;
STICKLINE(TJ1 AND TJ2 AND TJ0 AND TJ3,H,H*1.19,0,0),COLORRED;
{世纪大底
VAR3U:=(CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100;
VAR4U:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;
VAR5U:=(CLOSE-MA(CLOSE,32))/MA(CLOSE,32)*100;
VAR6U:=(VAR3U+VAR4U+VAR5U)/3;
VAR8U:=IF(VAR6U<=-20,10,0);
VAR9U:=HHV(VAR8U,10);
VARAU:=IF(VAR9U AND CROSS(MA(CLOSE,3),MA(CLOSE,5)),20,0);
DRAWTEXT(VARAU=20,H*1.25,'世纪大底'),COLORYELLOW;
STICKLINE(VARAU=20,H,H*1.25,0.1,0),COLORYELLOW;}
{愚公买入}
NY:=2;
MY:=3;
VAR3Y:=REF(HIGH,1)*1.1;
VAR4Y:=HIGH*1.1;
VAR5Y:=(VAR4Y*VOL+VAR3Y*(CAPITAL-VOL))/CAPITAL;
VAR6Y:=REF(LOW,1)*0.9;
VAR7Y:=LOW*0.9;
VAR8Y:=(VAR7Y*VOL+VAR6Y*(CAPITAL-VOL))/CAPITAL;
VAR9Y:=EMA(VAR8Y,30);
VARAY:=EMA(VAR5Y,30);
VARBY:=VARAY-2;
VARCY:=IF(CLOSE<=VAR9Y,VARBY,VARAY);
DRAWTEXT(FILTER(VARCY-VARBY=0 AND CROSS((EMA(EMA(EMA(CLOSE,NY),NY),NY)-REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1))/REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1)*100,MA((EMA(EMA(EMA(CLOSE,NY),NY),NY)-REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1))/REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1)*100,MY)),4),H*1.25,'愚买入'),COLORRED;
STICKLINE(FILTER(VARCY-VARBY=0 AND CROSS((EMA(EMA(EMA(CLOSE,NY),NY),NY)-REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1))/REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1)*100,MA((EMA(EMA(EMA(CLOSE,NY),NY),NY)-REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1))/REF(EMA(EMA(EMA(CLOSE,NY),NY),NY),1)*100,MY)),4),H,H*1.25,0.1,0),COLORRED;
{伏击涨停}
MA3DR:=MA(C,3);
MA5DR:=MA(C,5);
ZXR:=(MA3DR+MA5DR)/2;
MA20DR:=MA(C,20);
MA30DR:=MA(C,30);
QSXSR:=MA5DR>=MA30DR AND MA30DR>REF(MA30DR,1);
GDR:=ZXR>=REF(ZXR,1) AND REF(ZXR,1)<REF(ZXR,2);
YBR:=C>REF((O-C)/2+C,2);
买R:=CROSS(C,ZXR) AND (GDR OR YBR) AND QSXSR;
优R:=买R AND MA5DR>REF(MA5DR,1);
{DRAWTEXT(优R,L*0.99, '伏击涨停'),COLORRED;}
{老牛嫩草}
{DRAWTEXT(买R,L*0.99, '波段伏击');};
H1:=-100*(HHV(C,3)-C)/(HHV(C,3)-LLV(L,3))+100; H2:=-100*(HHV(C,10)-C)/(HHV(C,10)-LLV(L,10))+100;
H3:=INTPART((SUM(C*V*100,21)/SUM(V*100,22))*100)/100;
H4:=EMA(C,5)-EMA(C,10);
H5:=EMA(H4,9); H6:=H5-REF(H5,1); H7:=H4-REF(H4,1);
H8:=REF(IF((MA(C,5)-C)/C>0.02 AND (MA(C,20)-MA(C,5))/MA(C,5)
>0.06,1,0),2);
老牛嫩草:=IF(CROSS(H4,H5) AND H4<0 AND H5<-0.2 AND H6>0 AND
(H1>45 OR H2>45 OR H3>45) AND
H8,1,0);
DRAWTEXT(老牛嫩草,L*0.85, '老牛嫩草'),COLORYELLOW;
STICKLINE(老牛嫩草,L,L*0.85,0,0),COLORYELLOW;
{全仓买进}
VAR1H:=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);
VAR2H:=EMA(VAR1H,8);
VAR3H:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1),3,1);
趋势H:=EMA(VAR3H,3)-10;
趋势线H:=趋势H,COLORFF00FF;
DRAWTEXT(CROSS(趋势线H,VAR2H)AND 趋势线H>REF(趋势线H,1)AND 趋势线H<50,L*0.90,'全仓买进\'),COLORYELLOW;
{钱机买入}
QW1:=(HIGH+LOW+CLOSE*2)/4;
QW3:=EMA(QW1,10);
QW4:=STD(QW1,10);
QW5:=(QW1-QW3)*100/QW4;
QW6:=EMA(QW5,5);
ZZ:=EMA(QW6,10)+100/2-5;
DDDD:=EMA(ZZ,4);
DRAWTEXT(CROSS(ZZ,DDDD) AND DDDD<20 AND DDDD>-10,H*1.101,'钱机买入'),COLORCCFF99;
STICKLINE(CROSS(ZZ,DDDD) AND DDDD<20 AND DDDD>-10,H,H*1.101,0,0),COLORCCFF99;
{钱机看涨}
多线:=IF(CROSS(ZZ,DDDD) AND DDDD<-10,30,0),LINETHICK1,COLORFF00FF;
DRAWTEXT(多线>0,L*0.80,'看涨'),COLOR0000FF;
STICKLINE(多线>0,L,L*0.80,0,0),COLOR0000FF;
{反转向上}
VAR2M:=MA(CLOSE, 5);
VAR3M:=MA(CLOSE, 10);
VAR4M:=MA(CLOSE, 20);
VAR5M:=MA(CLOSE, 30);
VAR6M:=(VAR2M+VAR3M+VAR4M+VAR5M)/4;
VAR7M:=(VAR6M-REF(VAR6M, 15))/REF(VAR6M, 15)*100;
VAR9M:=EMA(VAR7M, 8);
FZXS:=(VAR9M>REF(VAR9M,1) AND REF(VAR9M,1)<REF(VAR9M,2))>0;
DRAWTEXT(FZXS,L*0.95,'反转向上'),COLOREE00EE;
{圣灵石2:=FILTER(IF(((SMA(((CLOSE - LLV(LOW,54)) / (HHV(HIGH,54) -LLV(LOW,54)) * 100),7,1)) * 16.18) - ((SMA(SMA((((CLOSE- LLV(LOW,54)) / (HHV(HIGH,54) - LLV(LOW,54))) *100),7,1),5,1)) *10.9)<=(SMA(SMA((((CLOSE- LLV(LOW,54)) / (HHV(HIGH,54) - LLV(LOW,54))) *100),7,1),5,1)) AND EMA(IF(L<=LLV(L,34),MA(SMA(ABS(L-REF(LOW,1)),13,1)/SMA(MAX(L-REF(LOW,1),0),13,1)*100,13),0),3)>REF(EMA(IF(L<=LLV(L,34),MA(SMA(ABS(L-REF(LOW,1)),13,1)/SMA(MAX(L-REF(LOW,1),0),13,1)*100,13),0),3),1),EMA(IF(L<=LLV(L,34),MA(SMA(ABS(L-REF(LOW,1)),13,1)/SMA(MAX(L-REF(LOW,1),0),13,1)*100,13),0),3)*8,0),20),COLORFF00FF;
DRAWTEXT(圣灵石2,L*0.75,'多空对接'),COLORYELLOW;
STICKLINE(圣灵石2,L,L*0.75,0,0),COLORYELLOW;}
{牛熊抄底}
VAR1T:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*100;
VAR2T:=SMA(VAR1T,3,1);
VAR3T:=SMA(VAR2T,3,1);
VAR4T:=SMA(VAR3T,3,1);
VAR6T:=CROSS(VAR3T,VAR4T) AND VAR3T<20;
DRAWTEXT(FILTER(VAR6T,10)=1,H*1.20,'●抄底'),COLORYELLOW;
{很准杀入}
VAR10N1:=LLV(LOW,10);
VAR13N1:=HHV(HIGH,25);
MN1:=EMA((CLOSE-VAR10N1)/(VAR13N1-VAR10N1)*4,4)*25,COLORYELLOW,;
RSV10N1:= (HHV(HIGH,11)-CLOSE)/(HHV(HIGH,11)-LLV(LOW,11))*100;
LWR1N1:=SMA(RSV10N1,3,1),COLORRED,LINETHICK2;
LWR2N1:=SMA(LWR1N1,3,1),COLORWHITE;
LCN1:=REF(CLOSE,1);
RSIN1:=SMA(MAX(CLOSE-LCN1,0),4.1,1)/SMA(ABS(CLOSE-LCN1),4.1,1)*100;
很准杀入:=CROSS(RSIN1,11)*7,COLORRED;
DRAWTEXT(很准杀入,H*1.15,'很准杀入'),COLORYELLOW;
很杀入:STICKLINE(很准杀入,H,H*1.5,0.1,0),COLORYELLOW;
{跟庄买入}
VAR3L:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1),3,1);
趋势L:=EMA(VAR3L,3)-10;
VAR4L:=(趋势L-REF(趋势L,1))/REF(趋势L,1)*100;
VAR5L:=FILTER((趋势L<=13 AND VAR4L>13),10);
DRAWTEXT(VAR5L,H*1.28,'庄买入'),COLORWHITE;
STICKLINE(VAR5L,H,H*1.28,0,0),COLORWHITE;
{牛熊逃顶}
VAR7T:=CROSS(VAR4T,VAR3T) AND VAR3T>80;
DRAWTEXT(FILTER(VAR7T,5)=1,HIGH * 1.10 ,'●逃顶') ,COLORGREEN;
{官人入门}
VAREB:=(REF(LOW,1))*(0.89999997);
VARFB:=(LOW)*(0.89999997);
VAR10B:=((VARFB)*(VOL)+(VAREB)*(CAPITAL-VOL))/(CAPITAL);
VAR11B:=EMA(VAR10B,30);
VAR12B:=CLOSE-REF(CLOSE,1);
VAR13B:=MAX(VAR12B,0);
VAR14B:=ABS(VAR12B);
VAR15B:=((SMA(VAR13B,7,1))/(SMA(VAR14B,7,1)))*(100);
VAR16B:=((SMA(VAR13B,13,1))/(SMA(VAR14B,13,1)))*(100);
VAR17B:=BARSCOUNT(CLOSE);
VAR18B:=((SMA(MAX(VAR12B,0),6,1))/(SMA(ABS(VAR12B),6,1)))*(100);
VAR19B:=(((-200))*(HHV(HIGH,60)-CLOSE))/(HHV(HIGH,60)-LLV(LOW,60))+100;
VAR1AB:=((CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15)))*(100);
VAR1BB:=SMA((SMA(VAR1AB,4,1)-50)*(2),3,1);
VAR1CB:=((INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14)))*(100);
VAR1DB:=SMA(VAR1CB,4,1);
VAR1EB:=SMA(VAR1DB,3,1);
VAR1FB:=((HHV(HIGH,30)-CLOSE)/(CLOSE))*(100);
VAR20B:=(VAR18B<=25) AND (VAR19B<(-95)) AND (VAR1FB>20) AND (VAR1BB<(-30)) AND (VAR1EB<30) AND (VAR11B-
CLOSE>=(-0.25)) AND (VAR15B<22) AND (VAR16B<28) AND (VAR17B>50);
官人入门:=IF(VAR20B,40,0),COLORFFCC66,LINETHICK2;
{底部建仓}
KAR5:=LLV(LOW,26);
KAR6:=HHV(HIGH,34);
KAR7:=EMA((CLOSE-KAR5)/(KAR6-KAR5)*4,4)*25;
QTYG:=KAR7<10;
DRAWTEXT(QTYG,铁底 * 0.99 ,'建') ,COLORGREEN;
{强势追涨}
{RSV3Y:=(((CLOSE - LLV(LOW,8)) / (HHV(HIGH,8) - LLV(LOW,8))) * 100);
KK5Y:=INTPART(SMA(RSV3Y,3,1));
K11Y:=SMA(RSV3Y,3,1);
DD5Y:=INTPART(SMA(K11Y,3,1));
N1Y:=(KK5Y + DD5Y);
KXY:=(N1Y < 25);
KX1Y:=REF(KXY,29);
RVY:=(CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100;
股市黑客:=SMA(RVY,3,1);
WY:=((-((100)*(HHV(H,21) - C))/(HHV(HIGH,21) - LLV(L,21)))),LINETHICK2;
RGY:=(CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100;
KK1Y:=EMA(SMA(RGY,3,1),2),COLORFFFFFF;
DD2Y:=SMA(KK1Y,3,1),COLOR00FFFF;
DRAWTEXT(CROSS(WY,-2) AND CROSS(股市黑客,普通投资者) AND CROSS(KK1Y,DD2Y),H*1.20,'强势追涨'),COLORYELLOW};
{黑马起步}
{X1B:=(((((3 * CLOSE) + HIGH) + LOW) + OPEN) / 6);
X2B:=EMA(X1B,10);
VAR1B:=EMA(CLOSE,8);
VAR2B:=EMA(VAR1B,20);
VAR3B:=CROSS(VAR1B,VAR2B);
VAR4B:=(VAR1B < MA(CLOSE,60));
黑马起步:=(VAR3B AND VAR4B);
均线:=MA(CLOSE,16);
DRAWTEXT((((黑马起步 > 0) AND (LOW <= X2B)) AND ((均线 - REF(均线,1)) > 0)),极底*1.05,'起步'),COLOR00FF00;}
{脉冲}
VAR2D:=IF(MONTH<12,1,1);
VAR3D:=(2*CLOSE+HIGH+LOW)/4;
VAR4D:=LLV(LOW,34);
VAR5D:=HHV(HIGH,34);
主力D:=EMA((VAR3D-VAR4D)/(VAR5D-VAR4D)*100,13)*VAR2D,LINETHICK4,COLORRED;
散户D:=EMA(0.667*REF(主力D,1)+0.333*主力D,2),LINETHICK2,COLORFF9933;
买入脉冲:=CROSS(主力D,散户D) AND 主力D<35;
DRAWTEXT(买入脉冲,顶线*1.02,'脉冲入'),COLORYELLOW;
{VAR198:=REF(LOW,1);
VAR298:=SMA(ABS(LOW-VAR198),3,1)/SMA(MAX(LOW-VAR198,0),3,1)*100;
VAR398:=EMA(IF(CLOSE*1.2,VAR298*10,VAR298/10),3);
VAR498:=LLV(LOW,38);
VAR598:=HHV(VAR398,38);
VAR698:=IF(LLV(LOW,90),1,0);
VAR798:=EMA(IF(LOW<=VAR498,(VAR398+VAR598*2)/2,0),3)/618*VAR698;
XG98:=IF(VAR798>=100,100,VAR798);}
{DRAWTEXT(XG98,铁底 * 0.89 ,'吸') ,COLORGREEN;};
{短线擒黑马}
LC:=REF((O+H+L+2*C)/5,1);
RSI:=SMA(MAX(C-LC,0),7,1)/SMA(ABS(C-LC),7,1)*10;
TYP:=(HIGH+LOW+CLOSE)/3;
cci:=(TYP-MA(TYP,23))/(0.015*AVEDEV(TYP,23));
买:=CROSS(RSI,7.1) AND MA(V,5)>MA(V,10),COLORRED;
DRAWTEXT(CROSS(RSI,7.1) AND MA(V,5)>MA(V,10),L,'↖◆◆短线擒黑马◆◆'),COLORWHITE;
DRAWICON(买,(LOW * 0.98),17);
卖:=CROSS(7.1,RSI) AND MA(V,10)>MA(V,5),COLORGREEN;
DRAWTEXT(CROSS(7.1,RSI) AND MA(V,10)>MA(V,5),H*1.04,'■■■逃跑■■■'),COLORGREEN;
DRAWICON(卖,(H*1.03),28);
{不赚都难}
AAQ:=RANGE(MA(C,13) ,O,C)+RANGE(MA(C,13) ,O,C)+RANGE(MA(C,21) ,O,C)+RANGE(MA(C,34) ,O,C)
+RANGE(MA(C,55) ,O,C)+RANGE(MA(C,144) ,O,C)+RANGE(MA(C,233) ,O,C);
AAAQ:=IF(CURRBARSCOUNT=1,VOL*240/FROMOPEN/REF(VOL,1)-1,VOL/REF(VOL,1)-1);
WWQ:=AAQ>=3 AND AAAQ>=1;
DRAWTEXT(WWQ,L*0.97,'不赚都难'),COLORWHITE;
通达信RSI合并威廉指标公式