通达信网综合主图继续完善 源码
{参数:N 1 100 5;S 0 2 2}
A11:=(REF(EMA(CLOSE,5),1));
B:=CROSS(EMA(CLOSE,5),EMA(SLOPE(CLOSE,21)*20+CLOSE,42));
DRAWTEXT(B,LOW*0.995,'追'),COLORFFFF00,LINETHICK2;
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
DRAWTEXT(CROSS(J,D),LOW*0.98,'加'),COLOR00FFFF,LINETHICK2;
VAR29:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*100;
VAR2A:=SMA(VAR29,5,1);
VAR2B:=SMA(VAR2A,10,1);
VAR2C:=CROSS(VAR2B,VAR2A);
VAR2D:=VAR2B>80 OR VAR2A>80;
VAR2E:=VAR2C AND VAR2D;
VAR33:=HIGH;
VAR34:=LOW;
逃顶:=STICKLINE(VAR2E,VAR33,VAR34,4,0);
DRAWTEXT(CROSS((REF(HIGH,1)+REF(LOW,1))/2,MA(CLOSE,20)+2*STD(CLOSE,20)),HIGH*1.01,'抛'),COLORGREEN;
X6:=REF(CLOSE,1);
X7:=SMA(MAX(CLOSE-X6,0),7,1)/SMA(ABS(CLOSE-X6),7,1)*100;
X8:=CROSS(79,X7);
X9:=FILTER(X8,4);DRAWTEXT(X9,HIGH*1.03,'出货'),COLOR9000F5;
STICKLINE(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L,OPEN,3.15,0),COLOR337777;
STICKLINE(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L,OPEN,2.45,0),COLOR339999;
STICKLINE(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L,OPEN,1.75,0),COLOR33BBBB;
STICKLINE(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L,OPEN,1.05,0),COLOR33DDDD;
STICKLINE(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L,OPEN,0.35,0),COLOR33FFFF;
DRAWTEXT(CROSS(0.9,1/VOL*1000>0.01 AND "KDJ.J"<0),L*0.99,'地量买点'),COLOR33FFFF;
DRAWTEXT(CROSS(88,RSI),(HIGH*1.01),'R背'),COLOR00FF00;
VAR2S:=(2*CLOSE+HIGH+LOW)/4;
VAR3S:=IF(YEAR>=2099 AND MONTH>2,0,1);
VAR4S:=LLV(LOW,5);
VAR5S:=HHV(HIGH,4);
散户:=EMA((VAR2S-VAR4S)/(VAR5S-VAR4S)*100,4)*VAR3S;
庄家:=EMA(0.667*REF(散户,1)+0.333*散户,2)*VAR3S;
STICKLINE(CROSS(散户,庄家) AND 散户<30,L,OPEN,3.15,0),COLOR770077;
STICKLINE(CROSS(散户,庄家) AND 散户<30,L,OPEN,2.45,0),COLOR990099;
STICKLINE(CROSS(散户,庄家) AND 散户<30,L,OPEN,1.75,0),COLORBB00BB;
STICKLINE(CROSS(散户,庄家) AND 散户<30,L,OPEN,1.05,0),COLORDD00DD;
STICKLINE(CROSS(散户,庄家) AND 散户<30,L,OPEN,0.35,0),COLORFF00FF;
DRAWTEXT(CROSS(散户,庄家) AND 散户<30,L*0.99,'吸'),COLORFF00FF;
DMLJ:=HHV(H,120);
E:=(H+L+O+2*C)/5;
CRTP:=E+(H-L);
CRZL:=2*E-L;
CRZC:=2*E-H;
CRFZ:=E-(H-L);
CRXL:=(E+CRTP+CRZL+CRZC+CRFZ)/5;
高:=CONST(CRTP),COLORRED;
阻:=CONST(CRZL),COLORC7C9FF;
支:=CONST(CRZC),COLOR7C9CFF;
反:=CONST(CRFZ),COLORDD00DD;
心理:=CONST(CRXL);
高压:DRAWLINE(S>1&&CURRBARSCOUNT=5+1,高,ISLASTBAR,高,1),COLOR0000FF;
阻力:DRAWLINE(S>1&&CURRBARSCOUNT=5+1,阻,ISLASTBAR,阻,1),COLOR0099FF;
支撑:DRAWLINE(S>1&&CURRBARSCOUNT=5+1,支,ISLASTBAR,支,1),COLORGREEN;
反转价:DRAWLINE(S>1&&CURRBARSCOUNT=5+1,反,ISLASTBAR,反,1),COLORDD00DD;
次日心理价:DRAWLINE(S>1&&CURRBARSCOUNT=5+1,心理,ISLASTBAR,心理,1),COLORFFFFFF;
DRAWTEXT(ISLASTBAR,反,' 反 转少量买'),LINETHICK1,COLORDD00DD;
DRAWTEXT(ISLASTBAR,支,' 支 撑'),LINETHICK1,COLOR00FF00;
DRAWTEXT(ISLASTBAR,阻,' 阻 力'),LINETHICK1,COLOR0099FF;
DRAWTEXT(ISLASTBAR,高,' 高 压'),LINETHICK1,COLOR0000FF;
T1:=CONST(LLVBARS(LOW,10));
T1HIGH:=CONST(REF(HIGH,T1));
CC:=CONST(CURRBARSCOUNT);
T2:=CONST(BARSLAST(CURRBARSCOUNT>CC+T1 AND H>T1HIGH));
T2HIGH:=CONST(REF(HIGH,T2));
T3:=CONST(BARSLAST(CURRBARSCOUNT>CC+T2 AND HIGH>T2HIGH));
T3HIGH:=CONST(REF(HIGH,T3));
猎击线:DRAWLINE(CURRBARSCOUNT=T3+1, T3HIGH, ISLASTBAR, T3HIGH, 1),COLOR00FFFF,LINETHICK1;
DRAWTEXT(ISLASTBAR, T3HIGH, '网出击买入')LINETHICK1,COLOR00FFFF;
IF(S=1, CRTP,DRAWNULL),COLORRED;
IF(S=1, CRZL,DRAWNULL),COLORC7C9FF;
IF(S=1, CRZC,DRAWNULL),COLOR7C9CFF;
IF(S=1, CRFZ,DRAWNULL),COLORDD00DD;
IF(S=1, CRXL,DRAWNULL),COLORFFDDFF;
A:=(3*C+H+L+O)/6;
XJ:=(A+0.618*REF(A,1)+0.382*REF(A,2)+0.236*REF(A,3)+0.146*REF(A,4))/2.382;
YCZXH:=(MA(HHV(A,2),5)+MA(HHV(A,2),13)+MA(HHV(A,2),21)+MA(HHV(A,2),32))/4;
YCZXL:=(MA(LLV(A,2),5)+MA(LLV(A,2),13)+MA(LLV(A,2),21)+MA(LLV(A,2),32))/4;
PJ:=(10*A+9*REF(A,1)+8*REF(A,2)+7*REF(A,3)+6*REF(A,4)+5*REF(A,5)+4*REF(A,6)+3*REF(A,7)+2*REF(A,8)+REF(A,9))/55;
A1:=EMA(PJ,3),COLOR004000;A2:=EMA(PJ,5),COLOR004000;
A3:=EMA(PJ,7),COLOR004000;A4:=EMA(PJ,9),COLOR004000;
A5:=EMA(PJ,11),COLOR004000;
LX:=REF(XJ,1);
ZD:=(SMA(MAX(XJ-LX,0),5,1)/SMA(ABS(XJ-LX),5,1))*100;
KX1:=(CLOSE>=OPEN) AND ZD>=50;
KX2:=(CLOSE<OPEN) AND ZD>=50;
KX3:=(CLOSE>=OPEN) AND ZD<50;
KX4:=(CLOSE<OPEN) AND ZD<50;
AAA2:=SUM(IF( CLOSE>REF(CLOSE,1),VOL*C,0),0);
AAA3:=SUM(IF( CLOSE<REF(CLOSE,1),VOL*C,0),0);
AAA4:=SUM(IF( CLOSE=REF(CLOSE,1),VOL*C,0),0);
BBB1:=0;
B1万元:=DVOL*DCLOSE/100;
B1差:=B1万元-REF(B1万元,1);
B2万元:=DVOL*DCLOSE/100;
B2比:=B2万元/REF(B2万元,1);
净流入万元:=(AAA2-AAA3-0.5*AAA4);
PM:=MA(净流入万元,1);
PMA:=PM/REF(PM,1)>1;
PMB:=REF(PMA,1)<1 AND PMA;
密码:=(EMA(MA(B1万元,2),2))/100000,COLORYELLOW,NODRAW;
二日比:=密码/REF(密码,1);
选股:=PMB AND 密码>REF(密码,1) AND 二日比>1 ,COLORRED,NODRAW;
均价线:=AMOUNT/V/100;
均价线2:=MA(均价线,3);
均价线5:=MA(均价线,5);
均价线10:=MA(均价线,10);
均价线30:=MA(均价线,30);
突破:=C>均价线2 AND 均价线2<REF(均价线2,1) AND REF(均价线2,1)<REF(均价线2,2)
AND REF(均价线2,2)<REF(均价线2,3) AND 选股;
STICKLINE(突破,H,L,5,0),LINETHICK1,COLORRED;
STICKLINE(突破,H,L,0.2,0),COLORYELLOW;
STICKLINE(突破,O,C,2,0),LINETHICK1,COLORYELLOW;
STICKLINE(突破,O,C,3,0),LINETHICK1,COLORMAGENTA;
STICKLINE(突破,H,L,0,1),COLORMAGENTA;
DRAWTEXT_FIX(ISLASTBAR,0,0,0,GNBLOCK);
均线:=EXPMA(C,12),COLORGRAY,LINETHICK2;
日:=50;昨前:=3;
高1:=REF(HHV(H,日),昨前);
低1:=REF(LLV(L,日),昨前);
H4:=高1-(高1-低1)*0.618;
H5:=高1-(高1-低1)*0.809;
支撑80.9%:REFDATE(H5,DATE),COLORRED;
支撑61.8%:REFDATE(H4,DATE),COLORGREEN,LINETHICK1;
STICKLINE(CURRBARSCOUNT=1,支撑80.9%,支撑80.9%,1000,-1),COLORGREEN;
STICKLINE(CURRBARSCOUNT=1,支撑61.8%,支撑61.8%,1000,-1),COLORRED;
DRAWTEXT(CURRBARSCOUNT=30 AND 支撑61.8%,支撑61.8%,'线上买持股, 线下卖持币');
DRAWTEXT(CURRBARSCOUNT=1 AND 支撑61.8%,支撑61.8%,'命运转折线'),COLORRED;
AA17:=EMA(C,14)COLORWHITE,LINETHICK1;
A17X:=(AA17-REF(AA17,1))/REF(AA17,1)*100,NODRAW;
参考线试买:IF(A17X>=0,REF(EMA(C,14),BARSLAST(CROSS(A17X,0))+1),DRAWNULL)COLORRED,LINETHICK2;
DRAWTEXT(ISLASTBAR,参考线试买,'参考线试买'),COLORYELLOW;
Y:=(H+L)/2;
AO:=MA(Y ,5 )-MA(Y ,34 );
DU0:=CROSS(AO,0);
UD0:=CROSS(0,AO);
TDU0:=BARSLAST(DU0);
TUD0:=BARSLAST(UD0);
DU3:=REF(DU0,1);
UD3:=REF(UD0,1);
TDU3:=BARSLAST(DU3);
TUD3:=BARSLAST(UD3);
网决策线:IF(TDU3<TUD3,REF(HHV(H,2),TDU3),REF(LLV(L,2),TUD3)),COLORYELLOW;
DRAWTEXT(ISLASTBAR,网决策线,'网决策线'),COLORYELLOW;
网5:=EMA(CLOSE,5)COLORLIGRAY,LINETHICK2;
网33:=EXPMA(CLOSE,33),COLORFF00FF,LINETHICK4;