通达信指标公式源码 分类资金流向 副图源码
通达信副图指标公式源码大全
副图指标公式源码1、百万踏浪(相传为杨百万看图公式)N1:=9;N:=3;V AR1:=REF(CLOSE,1);标尺: SMA(MAX(CLOSE-V AR1,0),5,1)/SMA(ABS(CLOSE-V AR1),5,1)*100;V AR2:=(CLOSE-LLV(LOW,N1))/(HHV(HIGH,N1)-LLV(LOW,N1))*100;V AR3:=SMA(V AR2,3,1);V AR4:=SMA(V AR3,3,1);V AR5:=SMA(V AR4,3,1);浪: V AR3,COLORBLUE;波: V AR4, COLORRED;段: V AR5 ,COLORYELLOW;V AR6:=CROSS(V AR3,VAR4) AND V AR4<25;STICKLINE(V AR6,0,V AR4+15,5,0), COLORGREEN;V AR7:=CROSS(V AR4,VAR5) AND V AR4<25;V AR8:=V AR7 AND VOL>REF(VOL,1)*2 AND VOL>REF(MA(VOL,5),1)*2; STICKLINE(V AR7,0,V AR4+55,5,0),COLORWHITE;DRAWTEXT(V AR7 AND COUNT(V AR7,10)=1,V AR4+25,'抄底'),COLORYELLOW; STICKLINE(V AR8,0,V AR4+15,5,0),COLORBLUE;DRAWTEXT(V AR8 AND COUNT(V AR8,10)=1,V AR4-1,'放量'),COLORGREEN;V AR9:=CROSS(V AR3,VAR4) AND V AR4>80 AND V AR4>VAR5;STICKLINE(V AR9 AND COUNT(V AR9,5)=1,V AR4-5,100,5,0),COLORYELLOW;V ARA:=CROSS(V AR5,V AR4) AND REF(V AR4,1)>80;STICKLINE(V ARA,V AR4-15,100,15,0), COLORYELLOW;DRAWTEXT(V ARA AND COUNT(V ARA,10)=1,V AR4-25,'逃顶'), COLORYELLOW; V AR1A:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;V AR1B:=SMA((SMA(V AR1A,4,1)-50)*2,3,1);V AR1C:=(INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14))*100; V AR1D:=SMA(V AR1C,4,1);V AR1E:=SMA(V AR1D,3,1);V AR1F:=(HHV(HIGH,30)-CLOSE)/CLOSE*100;V ARE:=REF(LOW,1)*0.9;V ARF:=LOW*0.9;V AR10:=(V ARF*VOL+V ARE*(CAPITAL-VOL))/CAPITAL;V AR11:=EMA(V AR10,30);V AR12:=CLOSE-REF(CLOSE,1);V AR13:=MAX(V AR12,0);V AR14:=ABS(V AR12);V AR15:=SMA(VAR13,7,1)/SMA(V AR14,7,1)*100;V AR16:=SMA(VAR13,13,1)/SMA(V AR14,13,1)*100;V AR17:=BARSCOUNT(CLOSE);V AR18:=SMA(MAX(V AR12,0),6,1)/SMA(ABS(V AR12),6,1)*100;V AR19:=(-200)*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60))+100;V AR20:=V AR18<=25 AND V AR19<-95 AND V AR1F>20 AND V AR1B<-30 AND V AR1E<30 AND V AR11-CLOSE>=-0.25 AND V AR15<22 AND V AR16<28 AND V AR17>50; STICKLINE(V AR20,0,50,10,0),LINETHICK2,COLORBLUE;DRAWTEXT(CROSS(V AR20,0.5) AND COUNT(V AR20=1,10)=1,60,'百万导弹?'),LINETHICK7,COLORWHITE;2、分类资金A:=IF((CLOSE>126.32),(AMOUNT)/(100000),VOL);主力:MA(A,4),LINETHICK0,COLORYELLOW;游资:MA(A,8),LINETHICK0,COLOR00FF00;大户:MA(A,16),LINETHICK0,COLORRED;散户:MA(A,32),LINETHICK0,COLORF0F000;主比:ABS(((主力)/(主力+ 游资+ 大户+ 散户))*(100)),LINESTICK,COLORYELLOW;游比:ABS(((游资)/(主力+ 游资+ 大户+ 散户))*(100)),LINESTICK,COLOR00FF00;大比:ABS(((大户)/(主力+ 游资+ 大户+ 散户))*(100)),LINESTICK,COLORRED;散比:ABS(((散户)/(主力+ 游资+ 大户+ 散户))*(100)),LINESTICK,COLORF0F000;警戒线:MA(A,180),COLORFF66FF,LINETHICK1;STICKLINE((主力> 0),0,主力,3,0),COLOR009CFF;STICKLINE((主力> 0),0,主力,2.8,0),COLOR009CFF;STICKLINE((主力> 0),0,主力,2.5,0),COLOR00C0FF;STICKLINE((主力> 0),0,主力,1.5,0),COLOR00D1FF;STICKLINE((主力> 0),0,主力,1,0),COLOR00EAFF;STICKLINE((主力> 0),0,主力,0.7,0),COLORYELLOW;STICKLINE((游资> 0),0,游资,3,0),COLOR00C100;STICKLINE((游资> 0),0,游资,2.8,0),COLOR00CA00;STICKLINE((游资> 0),0,游资,2.5,0),COLOR00D300;STICKLINE((游资> 0),0,游资,1.5,0),COLOR00DB00;STICKLINE((游资> 0),0,游资,1,0),COLOR00EA00;STICKLINE((游资> 0),0,游资,0.7,0),COLORGREEN;STICKLINE((大户> 0),0,大户,3,0),COLOR1020AA;STICKLINE((大户> 0),0,大户,2.8,0),COLOR1020BB;STICKLINE((大户> 0),0,大户,2.5,0),COLOR1020CC;STICKLINE((大户> 0),0,大户,1.5,0),COLOR1020DD;STICKLINE((大户> 0),0,大户,1,0),COLOR1020EE;STICKLINE((大户> 0),0,大户,0.7,0),COLORRED;STICKLINE((散户> 0),0,散户,3,0),COLORFF7700;STICKLINE((散户> 0),0,散户,2.8,0),COLORFF8800;STICKLINE((散户> 0),0,散户,2.5,0),COLORFF9900;STICKLINE((散户> 0),0,散户,1.5,0),COLORFFAA00; STICKLINE((散户> 0),0,散户,1,0),COLORFFBB00;STICKLINE((散户> 0),0,散户,0.7,0),COLORLIBLUE;3、黑马起爆点V AR1:=(CLOSE-MA(CLOSE,21))/MA(CLOSE,21)*100;V AR2:=(CLOSE-LLV(LOW,43))/(HHV(HIGH,43)-LLV(LOW,43))*100;V AR3:=SMA(V AR2,2,1);天:100+(-ABS(V AR1)),COLORRED;下:SMA(V AR3,2,1);无:ABS(V AR1),COLORGREEN;敌:50,COLORFFAA00,LINETHICK3;A:80;B:20;买:STICKLINE(CROSS(下,无),3,20,2,0),COLORRED,LINETHICK1;STICKLINE(CROSS(下,无),20,25,2,0),COLORFF9900,LINETHICK1;DRAWTEXT(CROSS(下,无),30,' '),COLORFFFFCC;卖:STICKLINE(CROSS(下,天),70,90,2,0),COLORRED,LINETHICK1;STICKLINE(CROSS(下,天),90,99,2,0),COLORFF9900,LINETHICK1;DRAWTEXT(CROSS(下,天),70,' '),COLORFFFFCC;选股2:IF(CROSS(下,20),1,0);DRAWICON((CROSS(下,20) ),20,1);DRAWICON((CROSS(下,20) ),-20,25);4、宁波绝密(相传为宁波涨停敢死队的绝密指标)WOL:IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL),NODRAW;STICKLINE(CURRBARSCOUNT=1 AND PERIOD=5,WOL,0,3,-1),COLORFFFFFF; VOLUME:VOL,VOLSTICK;V5:MA(VOLUME,5);V10:MA(VOLUME,10);V135:MA(VOLUME,135);V AR1:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));主买:IF(CLOSE>OPEN,V AR1*(HIGH-LOW),IF(CLOSE<OPEN,V AR1*((HIGH-OPEN)+(CLOSE -LOW)),VOL/2)),COLORRED,POINTDOT;主卖:IF(CLOSE>OPEN,V AR1*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,V AR1*(HIG H-LOW),VOL/2)),COLOR00FF00,POINTDOT;STICKLINE(主买>0,0,主买,2,0),COLORRED;{STICKLINE(主卖>0,主买,VOL,2,1),COLOR00FF80;}STICKLINE(主买<REF(主买,1)AND 主买>0,0,主买,2,0),COLOR00FFFF;换手:VOL/CAPITAL*100,POINTDOT;二十日换手:SUM(换手,20);5、起涨点换手率%:VOL/CAPITAL*100,LINETHICK0,COLORYELLOW;量比:V/(REF(MA(V,5),1)),LINETHICK0,COLORRED;VVOL:=IF(CURRBARSCOUNT=1 ANDPERIOD=5,VOL*240/FROMOPEN,DRAWNULL),NODRAW;虚拟量比:VVOL/(REF(MA(V,5),1)),LINETHICK0,COLORRED;获利比例%:WINNER(C)*100,COLORLIBLUE;涨幅%:(C-REF(C,1))/REF(C,1)*100,LINETHICK0;换手率%1:=换手率%>5;量比1:=量比>1.5 OR 虚拟量比>1.5;获利比例%1:=获利比例%>70;涨幅%1:=涨幅%>3;启动:=换手率%1 AND 量比1 AND 获利比例%1 AND 涨幅%1 ;起涨点:IF(启动,101,0)COLORRED,LINETHICK2;6、庄家建仓V AR1:=REF(LOW,1);V AR2:=SMA(ABS(LOW-V AR1),13,1)/SMA(MAX(LOW-VAR1,0),13,1)*4;V AR3:=EMA(VAR2,13);V AR4:=LLV(LOW,34);V AR5:=EMA(IF(LOW<=V AR4,V AR3,0),3);主力进场:STICKLINE(V AR5>REF(V AR5,1),0,V AR5,7,0 ),COLORRED;7、出色超赢JRH:=HHV(C,2);JRL:=LLV(C,2);MA3:=MA(CLOSE,3);YTSL:=(3*CLOSE+LOW+OPEN+HIGH)/6;V AR1:=(CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2));V AR2:=(REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR3:=(REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V AR4:=(REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR5:=(REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V AR6:=(REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR7:=(REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V AR8:=(REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR9:=(REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V ARA:=(REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V ARB:=(REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V ARC:=(REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V ARD:=(CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2));V ARE:=(REF(V ARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V ARF:=(REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR10:=(REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V AR11:=(REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); V AR12:=(REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); V AR13:=(REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));V AR14:=(REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));V AR15:=(REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));V AR16:=(REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));V AR17:=(REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));V AR18:=(REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));V AR19:=((REF(VARD OR V ARE OR V ARF OR V AR10 OR V AR11 OR V AR12 OR V AR13 OR V AR14 OR V AR15 OR VAR16 OR V AR17 OR V AR18,1)) AND V AR1);V AR1A:=((REF(VAR1 OR V AR2 OR V AR3 OR V AR4 OR V AR5 OR V AR6 OR V AR7 OR V AR8 OR V AR9 OR V ARA OR V ARB OR V ARC,1)) AND V ARD);红色持股:V AR1 OR V AR2 OR V AR3 OR V AR4 OR V AR5 OR V AR6 OR V AR7 OR V AR8 OR V AR9 OR V ARA OR V ARB OR V ARC,COLOR0000FF,NODRAW;离场:=IF(红色持股,JRL,DRAWNULL);明离场价:=离场,COLORFF99FF,NODRAW;今离场价:=REF(离场,1)COLOR0000FF,NODRAW;青色观望:V ARD OR V ARE OR V ARF OR VAR10 OR V AR11 OR V AR12 OR V AR13 OR V AR14 OR V AR15 OR VAR16 OR V AR17 OR V AR18,COLORFFFF00,NODRAW;进:=IF(青色观望,JRH,DRAWNULL);明进场价:=进,COLOR33AACC,NODRAW;今进场价:=REF(明进场价,1),COLORFF0000,NODRAW;黄色低买:V AR19,COLOR33AACC,NODRAW;洋红离场:V AR1A,COLORMAGENTA,NODRAW;急跌关注:(CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100<-14,COLORWHITE,NODRAW;上市日期年:REF(YEAR,BARSCOUNT(CLOSE)-1),NODRAW,COLOR0000FF;月:REF(MONTH,BARSCOUNT(CLOSE)-1),NODRAW,COLORFF00FF;日:REF(DAY,BARSCOUNT(CLOSE)-1),NODRAW,COLOR00FFFF;STICKLINE(ISLASTBAR AND (红色持股OR REF(红色持股,1)=1),今离场价,今离场价,30,1),COLOR0000FF;STICKLINE(ISLASTBAR AND (青色观望OR REF(青色观望,1)=1),今进场价,今进场价,30,1),COLOR00FF00;STICKLINE(C>=O,L,H,0,0),COLOR0000CC;STICKLINE(C<O,L,H,0,0),COLOR999900;STICKLINE(1,C,O,3.5,0),COLOR858500;STICKLINE(C>=O,C,O,3.5,0),COLOR0000E5;STICKLINE(红色持股,CLOSE,O,2.8,0),COLOR000055;STICKLINE(红色持股,CLOSE,O,2,0),COLOR000088;STICKLINE(红色持股,CLOSE,O,1.5,0),COLOR0000AA;STICKLINE(红色持股,CLOSE,O,1,0),COLOR0000CC;STICKLINE(红色持股,CLOSE,O,0.5,0),COLOR0000EE;STICKLINE(青色观望,CLOSE,O,2.8,0),COLOR555500;STICKLINE(青色观望,CLOSE,O,2,0),COLOR888800;STICKLINE(青色观望,CLOSE,O,1.5,0),COLORAAAA00;STICKLINE(青色观望,CLOSE,O,1,0),COLORCCCC00;STICKLINE(青色观望,CLOSE,O,0.5,0),COLOREEEE00;CO:=(C-O);STICKLINE(急跌关注,O,C-CO/2,2.8,0),COLOR555555;STICKLINE(急跌关注,O,C-CO/2,2,0),COLOR888888;STICKLINE(急跌关注,O,C-CO/2,1.5,0),COLORAAAAAA;STICKLINE(急跌关注,O,C-CO/2,1,0),COLORCCCCCC;STICKLINE(急跌关注,O,C-CO/2,0.5,0),COLOREEEEEE;STICKLINE(黄色低买,O,O+CO/3,2.8,0),COLOR335555;STICKLINE(黄色低买,O,O+CO/3,2,0),COLOR338888;STICKLINE(黄色低买,O,O+CO/3,1.5,0),COLOR33AAAA;STICKLINE(黄色低买,O,O+CO/3,1,0),COLOR33CCCC;STICKLINE(黄色低买,O,O+CO/3,0,0),COLOR33EEEE;STICKLINE(洋红离场,O,O+CO/3,2.8,0),COLOR550055;STICKLINE(洋红离场,O,O+CO/3,2,0),COLOR880088;STICKLINE(洋红离场,O,O+CO/3,1.5,0),COLORAA00AA;STICKLINE(洋红离场,O,O+CO/3,1,0),COLORCC00CC;STICKLINE(洋红离场,O,O+CO/3,0.5,0),COLOREE00EE;压力:MA(REF(HHV(C,30),1),2),POINTDOT,COLOR9DFFFF;支撑:MA(REF(LLV(C,30),1),2),POINTDOT,COLORABFF46;PMA:MA(C,5),COLORWHITE,LINETHICK2;IF(PMA>REF(PMA,1),PMA,DRAWNULL),COLORRED,LINETHICK2;IF(PMA<REF(PMA,1),PMA,DRAWNULL),COLORGREEN,LINETHICK2;X:=(3*C+L+O+H)/6;多空线:(20*X+19*REF(X,1)+18*REF(X,2)+17*REF(X,3)+16*REF(X,4)+15*REF(X,5)+14*REF(X, 6)+13*REF(X,7)+12*REF(X,8)+11*REF(X,9)+10*REF(X,10)+9*REF(X,11)+8*REF(X,12)+7*REF(X,13)+6*REF(X,14)+5*REF(X,15)+4*REF(X,16)+3*REF(X,17)+2*REF(X,18)+REF(X,20))/210,COLORFF00FF,LINETHICK2;DD:=多空线<REF(多空线,1);IF(DD,多空线,DRAWNULL),COLOR00FFFF,LINETHICK2;A:=(PMA>多空线);IF(A,多空线,DRAWNULL),COLOR33FF33,POINTDOT,LINETHICK4;RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;K:=SMA(RSV,9,1);D:=SMA(K,9,1);J:=3*K-2*D;X2:=LLV(J,2)=LLV(J,8);Y:=IF(CROSS(J,REF(J+0.01,1)) AND X2 AND J<20,30,0);DRAWTEXT(CROSS(J,REF(J+0.01,1)) AND X2 AND J<20,LOW*0.98,'★'),COLORYELLOW;8、彩色成交量STICKLINE(VOL > 0,VOL,0,3,0),COLOR333333;STICKLINE(VOL > 0,VOL,0,2.5,0),COLOR998855;STICKLINE(VOL > 0,VOL,0,1.7,0),COLORBBAA77;STICKLINE(VOL > 0,VOL,0,0.9,0),COLORDDCC99;STICKLINE(VOL > 0,VOL,0,0.04,0),COLORFFEEBB;换手:=VOL/CAPITAL*100,COLORRED;STICKLINE(换手>2 ,VOL ,CAPITAL*0.02,3,0),COLOR00AAAA; STICKLINE(换手>2 ,VOL ,CAPITAL*0.02,2.5,0),COLOR00CCCC; STICKLINE(换手>2 ,VOL ,CAPITAL*0.02,1.7,0),COLOR00EEEE; STICKLINE(换手>2 ,VOL ,CAPITAL*0.02,0.08,0),COLOR00FFFF; STICKLINE(换手>4 ,VOL ,CAPITAL*0.04,3,0 ),COLOR009900; STICKLINE(换手>4 ,VOL ,CAPITAL*0.04,2.5,0 ),COLOR00BB00; STICKLINE(换手>4 ,VOL ,CAPITAL*0.04,1.7,0 ),COLOR00DD00; STICKLINE(换手>4 ,VOL ,CAPITAL*0.04,0.8,0 ),COLOR00FF00; STICKLINE(换手>7 ,VOL ,CAPITAL*0.07,3,0),COLORBROWN; STICKLINE(换手>7 ,VOL ,CAPITAL*0.07,2.5,0),COLOR0000AA; STICKLINE(换手>7 ,VOL ,CAPITAL*0.07,1.7,0),COLOR0000CC; STICKLINE(换手>7 ,VOL ,CAPITAL*0.07,0.8,0),COLOR0000DD;五天均量:MA(VOL,5),COLORRED,LINETHICK0.01;廿天均量:MA(VOL,20),COLORWHITE,LINETHICK0.01;HSS:=V/CAPITAL*100,NODRAW;{显示当日换手}五天换手率:SUM(HSS,5),NODRAW;廿天换手率:SUM(HSS,20),NODRAW;抛压:STICKLINE(CROSS(84,RSI),0 ,VOL,1.5,0),COLORBLUE,LINETHICK5; V24:MA(VOL,24),COLORLIBLUE;V10:MA(VOL,10),COLORRED;V3:MA(VOL,3),COLORLIGRAY;9、涨停回马枪(有主图)均价线:=AMOUNT/V/100;C2:=REF(C,1);涨停:=IF(REF(C,1)*1.1-C<0.01 ,1,0);STICKLINE(涨停,0,5,6,0),COLORYELLOW;DRAWTEXT(涨停,8,'涨停'),COLORYELLOW;MA13:=MA(C,13),COLORGRAY;MA21:=MA(C,21),COLORWHITE;支撑线:=(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4; LC:=REF(CLOSE,1);操作线:=SMA(MAX(CLOSE-LC,0),2,1)/SMA(ABS(CLOSE-LC),2,1)*100;趋势线:=SMA(MAX(CLOSE-LC,0),14,1)/SMA(ABS(CLOSE-LC),14,1)*100; 震仓线:=45;震仓线2:=50;逃命线:=80;抄底线:=20;绝底线:=5;PP2:=操作线<震仓线2 AND REF(操作线,1)>震仓线2 ;PP:=操作线<震仓线AND REF(操作线,1)>震仓线;PP3:=操作线<抄底线AND REF(操作线,1)>抄底线;HH:=COUNT(涨停,13)>=1;STICKLINE(PP2 AND HH,0,5,3,0),COLORRED;STICKLINE(PP AND HH,0,5,3,0),COLORRED;STICKLINE(PP3 AND HH,0,5,3,0),COLORRED;DRAWTEXT(PP2 AND HH,8,'预警'),COLORRED;DRAWTEXT(PP AND HH,8,'预警'),COLORRED;DRAWTEXT(PP3 AND HH,8,'预警'),COLORRED;A:=SMA(L,4,3) ;绿色买入:IF (((A AND REF(PP,1) AND HH) OR (A AND REF(PP3,1) AND HH)),1,0 ); STICKLINE(A AND REF(PP,1) AND HH ,0,10,1,0),COLORGREEN;DRAWICON(A AND REF(PP,1) AND HH,12,1);STICKLINE(A AND REF(PP3,1) AND HH ,0,10,1,0)COLORGREEN;DRAWICON(A AND REF(PP3,1) AND HH,12,1);10、海风3号M1:=MA(CLOSE,1);M2:=(LOW+HIGH+CLOSE)/3;M3:= MA(M2,5);M4:= HHV(M3,10);Z:=HHV((M1<M4),10) OR HHV((M1<M4),10);S:=EMA(100*(CLOSE-LLV(LOW,34))/(HHV(HIGH,35)-LLV(LOW,34)),3); DRAWTEXT( FILTER(CROSS(S ,60 ),20),L*0.98,'▲'),COLORYELLOW ; {DRAWTEXT(FILTER( Z,9),H*1.028,'★') ,COLORBLUE;STICKLINE( S>60,O,C,4,0) ,COLORFF9BFB;}STICKLINE( S>60,O,C,2,0) ,COLORRED;{STICKLINE( S>60,O,C,1.5,0) ,COLORFD9BFB; }STICKLINE( S>60,H,L,0,0) ,COLORRED;{STICKLINE( S<60,O,C,4,0) ,COLOR01DC38;STICKLINE( S<60,O,C,2.5,0) ,COLOR01FE41;}STICKLINE( S<60,O,C,2,0) ,COLORGREEN;STICKLINE( S<60,H,L,0,0) ,COLORGREEN;V AR1:MA(CLOSE,5);V AR2:MA(CLOSE,10);V AR3:MA(CLOSE,20);V AR60:MA(CLOSE,60);V AR120:MA(CLOSE,120);V AR4:=OPEN<V AR1 OR OPEN<V AR2 OR OPEN<V AR3;V AR5:=CLOSE>MAX(V AR1,MAX(V AR2,MAX(V AR3,V AR60)));V AR6:=VOL/MA(VOL,30)>1.2;V AR7:=CLOSE/REF(CLOSE,1)>1.049;V AR8:=V AR4 AND V AR5 AND V AR6 AND V AR7;V AR9:=V AR8 AND (REF(BARSLAST(V AR8),1)>60 OR BARSSINCE(V AR8)=0); DRAWICON(V AR9 ,L*0.98,1) ;STICKLINE( VAR9,O,C,6,0) ,COLORYELLOW;STICKLINE( VAR9,H,L,0.6,0) ,COLORYELLOW;11、涨停时间窗(通达信金融终端副图)N:=13;WR大于80考虑买:100*(HHV(HIGH,N)-CLOSE)/(HHV(HIGH,N)-LLV(LOW,N)),LINETHICK0;均价:AMOUNT/(VOL*100),LINETHICK0,COLORYELLOW;ZT:=C/REF(C,1)>1.097;XH:=FILTER(ZT,13);BH:=BARSLAST(ZT);STICKLINE(ZT,0,L*1,3,0),COLORYELLOW;DRAWTEXT(ZT,L*1.1,'涨停'),COLORF00FF0;V ARZT:=BARSLAST(C/REF(C,1)>1.097);AA:=BETWEEN(C,REF(L,BH)*1.01,REF(L,BH)*0.987);STICKLINE(AA,0,L*0.5,2,0),COLORBLUE;DRAWTEXT(AA,L*0.6,'警戒'),COLORWHITE;STICKLINE(AA AND V ARZT=2,0,L*0.8,2,0),COLORRED;DRAWTEXT(AA AND V ARZT=2,L*0.9,'时间窗'),COLORWHITE;STICKLINE(AA AND V ARZT=4,0,L*0.8,2,0),COLORRED;DRAWTEXT(AA AND V ARZT=4,L*0.9,'时间窗'),COLORWHITE;STICKLINE(AA AND V ARZT=7,0,L*0.8,2,0),COLORRED;DRAWTEXT(AA AND V ARZT=7,L*0.9,'时间窗'),COLORWHITE;STICKLINE(AA AND V ARZT=12,0,L*0.8,2,0),COLORRED;DRAWTEXT(AA AND V ARZT=12,L*0.9,'时间窗'),COLORWHITE;STICKLINE(AA AND V ARZT=20,0,L*0.8,2,0),COLORRED;DRAWTEXT(AA AND V ARZT=20,L*0.9,'时间窗'),COLORWHITE;。
通达信指标公式源码主力资金副图指标
通达信指标公式源码主力资金副图指标通达信是一款常用的股票分析软件,其指标公式源码被广大投资者广泛使用。
主力资金副图指标是一种衡量市场主力资金流向的指标,通过计算买方力量与卖方力量之间的差异,从而判断市场的主力资金流入或流出情况。
以下是通达信主力资金副图指标的公式源码:```//主力资金指标公式AA:=C>REF(C,1)?(V-C):C<REF(C,1)?(V+C):V;//AA表示根据成交量和价格计算得到的主力资金V1:=SUM(V,5);//V1表示5日内的成交量合计V2:=SUM(V,10);//V2表示10日内的成交量合计AA1:=SUM(AA,5);//AA1表示5日内的主力资金合计AA2:=SUM(AA,10);//AA2表示10日内的主力资金合计MAV1:=MA(V,5);//MAV1表示成交量5日均线MAV2:=MA(V,10);//MAV2表示成交量10日均线MAAA1:=MA(AA,5);//MAAA1表示主力资金5日均线MAAA2:=MA(AA,10);//MAAA2表示主力资金10日均线COLORAA:IF(AA>0,4,7);//若主力资金大于0,则显示为绿色,否则显示为灰色COLORAA1:IF(AA1>0,4,7);COLORAA2:IF(AA2>0,4,7);//绘制主力资金副图Plot(AA,"AA",COLORAA,64);Plot(AA1,"AA1",COLORAA1,64);Plot(AA2,"AA2",COLORAA2,64);MAV1,MAV2,BARS,V1,V2,AA,AA1,AA2均为通达信中的基本指标函数,用来计算不同时间段内的成交量、主力资金、均线等数据。
以上的源码描述了主力资金指标的计算过程,包括根据成交量和价格计算得到主力资金、计算不同时间段内的主力资金合计、计算成交量和主力资金的均线等操作。
最牛通达信量化副图指标公式源码
最牛通达信量化副图指标公式源码
通达信量化副图指标公式源码有很多,以下是其中一些常用的指标公式源码:
1.MACD指标源码:
```
EMA(CLOSE,12)-EMA(CLOSE,26);
```
2.RSI指标源码:
```
SMA(MAX(CLOSE-LAST(CLOSE),0),N,1)/SMA(ABS(CLOSE-
LAST(CLOSE)),N,1)*100;
```
3.KDJ指标源码:
```
RSV:=100*(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N));
K:SMA(RSV,M1,1);
D:SMA(K,M2,1);
J:3*K-2*D;
```
4.BOLL指标源码:
```
BOLL:MA(CLOSE,N);
UB:BOLL+2*STD(BOLL,N);
LB:BOLL-2*STD(BOLL,N);
```
5.WR指标源码:
```
WR(N):100*(HHV(HIGH,N)-CLOSE)/(HHV(HIGH,N)-LLV(LOW,N));
```
6.OBV指标源码:
```
SUM(IF(CLOSE>REF(CLOSE,1),VOLUME,IF(CLOSE<REF(CLOSE,1),-VOLUME,0)),N);
```
以上是一些常见的通达信量化副图指标的源码,通过这些源码可以实现对应的指标计算。
需要注意的是,不同的量化策略会使用不同的指标,源码可能会有一定差异。
此外,这些源码只是指标的计算公式,并不包含完整的通达信指标的绘图等功能代码。
通达信指标公式源码 主力资金副图指标
ZLCM:=EMA(WINNER(CLOSE)*70,3);SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3); ZSHTL:=SHCM/(ZLCM+SHCM)*100;ZZLKP:=ZLCM/(ZLCM+SHCM)*100;ZCMZL:=MA(ZLCM+SHCM,13);ZZNTS:=BARSLAST(ZSHTL<90 AND REF(ZSHTL,1)>90);ZSHJJ:=EMA(ZSHTL,89);ZZLJJ:=EMA(ZZLKP,89);ZJLRQD:=INTPART(ZZLKP-ZZLJJ);SH8:=EMA(ZSHTL,8);DKB:=IF(ZZLKP-REF(ZZLKP,1)>ZSHTL-REF(ZSHTL,1),1,0);STICKLINE(REF(ZSHTL,1)>90 AND ZSHTL<90,ZSHTL,0,4,0),COLOR9966FF; STICKLINE(C>0,ZSHTL,ZZLKP,0,0),COLOREEEEEE;STICKLINE(ZSHJJ>REF(ZSHJJ,1),ZSHTL,ZSHJJ,1,0),COLORAAAAAA; STICKLINE(C>0,ZZLKP,0,3,0),COLORBLUE;STICKLINE(ZZLKP>75,ZZLKP,0,3,0),COLORFFFFFF;STICKLINE(ZZLJJ>REF(ZZLJJ,1),ZZLKP,ZZLJJ,3,0),COLORRED; STICKLINE(ZSHTL>=90,ZZLKP,0,3,0),COLORYELLOW;散户套牢系数:INTPART(ZSHTL),NODRAW;主力控盘系数:INTPART(ZZLKP),COLORCYAN,NODRAW;资金流入强度:ZJLRQD,NODRAW;RSV:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;K1:=SMA(RSV,10,1);D1:=SMA(K1,5,1);KK:=INTPART(K1);DD:=INTPART(D1);TFXXS:=KK+DD;TGLD:=MOD(TFXXS,10);TGLXS:=(TFXXS-REF(TFXXS,1))*10;TYCFX:=TFXXS+TGLXS;乖离系数:TGLXS,NODRAW,COLORGREEN;STICKLINE(TGLXS>0,150,150+TGLXS,3,0),COLOR000088;STICKLINE(TGLXS>0,150,150+TGLXS,2.5,0),COLOR000099;STICKLINE(TGLXS>0,150,150+TGLXS,2,0),COLOR0000AA;STICKLINE(TGLXS>0,150,150+TGLXS,1.5,0),COLOR0000BB;STICKLINE(TGLXS>0,150,150+TGLXS,1.0,0),COLOR0000DD; STICKLINE(TGLXS>0,150,150+TGLXS,0.5,0),COLOR0000FF;STICKLINE(TGLXS<0,150,150+TGLXS,3,0),COLOR008800;STICKLINE(TGLXS<0,150,150+TGLXS,2.5,0),COLOR00AA00;STICKLINE(TGLXS<0,150,150+TGLXS,2,0),COLOR00BB00;STICKLINE(TGLXS<0,150,150+TGLXS,1.5,0),COLOR00DD00; STICKLINE(TGLXS<0,150,150+TGLXS,1,0),COLOR00FF00;STICKLINE(TGLXS=0 ANDREF(TGLXS,1)>=0,150,150+TGLXS,8,0),COLORRED;STICKLINE(TGLXS=0 ANDREF(TGLXS,1)<0,150,150+TGLXS,8,0),COLORGREEN;风险系数:TFXXS,LINETHICK2,COLORYELLOW;预测风险:TYCFX,LINETHICK1,COLORCYAN;市场筹码总量:ZCMZL,COLORGREEN,LINETHICK1;上市:FINANCE(42)/10000,NODRAW,COLORYELLOW;STICKLINE(TGLXS>0 AND 100+TGLXS<TYCFX AND100+REF(TGLXS,1)>=REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLO W;STICKLINE(TGLXS<0 AND 100+TGLXS>=TYCFX AND100+REF(TGLXS,1)<REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLOW ;T1:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=1);T2:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=0);T3:=CONST( ZCMZL=REF(ZCMZL,1));T4:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=1);T5:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=0);T6:=CONST(TFXXS<=50 );T7:=CONST(TFXXS>=160 );T8:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS<=100 );T9:=CONST( TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS>100);T10:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) AND TFXXS>100 );T11:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) AND TFXXS<=100 );T12:=CONST( ZSHTL>90 );T13:=CONST( ZZLKP>75 );T14:=CONST(CROSS(ZCMZL,ZZLJJ) AND ZZLKP>ZZLJJ AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T15:=CONST(CROSS(ZCMZL,ZZLKP) AND ZZLKP>ZZLJJ AND ZZLKP<ZSHTL AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T16:=CONST( CROSS(ZCMZL,ZSHTL) AND ZSHTL>ZZLKP ANDZCMZL>REF(ZCMZL,1));T17:=CONST( CROSS(ZCMZL,100) AND ZCMZL>REF(ZCMZL,1));T18:=CONST(REF(ZSHTL,1)>90 AND ZSHTL<90 );TS1:=IF(T1=1,0+0.03,0);TS2:=IF(T2=1,TS1+0.03,TS1);TS3:=IF(T3=1,TS2+0.03,TS2);TS4:=IF(T4=1,TS3+0.03,TS3);TS5:=IF(T5=1,TS4+0.03,TS4);TS6:=IF(T6=1,0+0.73,0);TS7:=IF(T7=1,TS6+0.03,TS6);TS8:=IF(T8=1,TS7+0.03,TS7);TS9:=IF(T9=1,TS8+0.03,TS8);TS10:=IF(T10=1,TS9+0.03,TS9);TS11:=IF(T11=1,TS10+0.03,TS10);TS12:=IF(T12,0+0.03,0);TS13:=IF(T13=1,TS12+0.03,TS12);TS14:=IF(T14=1,TS13+0.03,TS13);TS15:=IF(T15=1,TS14+0.03,TS14);TS16:=IF(T16=1,TS15+0.03,TS15);TS17:=IF(T17=1,TS16+0.03,TS16);TS18:=IF(T8=1,TS17+0.03,TS17);DRAWTEXT_FIX(T1,0.58,TS1,0,'★主力动向监控:主力增仓'),COLORRED; DRAWTEXT_FIX(T2,0.58,TS2,0,'★主力动向监控:主力减仓'),COLORMAGENTA; DRAWTEXT_FIX(T3,0.58,TS3,0,'★主力动向监控:多空平衡'),COLORGRAY; DRAWTEXT_FIX(T4,0.58,TS4,0,'★主力动向监控:主力回补'),COLORFF9933; DRAWTEXT_FIX(T5,0.58,TS5,0,'★主力动向监控:主力出逃'),COLORGREEN; DRAWTEXT_FIX(T6,0.78,TS6,0,'★操作风险提示:买入风险'),COLORYELLOW; DRAWTEXT_FIX(T7,0.78,TS7,0,'★操作风险提示:卖出风险'),COLORCYAN; DRAWTEXT_FIX(T8,0.78,TS8,0,'★操作风险提示:追涨博弈'),COLORRED; DRAWTEXT_FIX(T9,0.78,TS9,0,'★操作风险提示:稳健持股'),COLORMAGENTA; DRAWTEXT_FIX(T10,0.76,TS10,0,'★操作风险提示:盘跌减仓'),COLORWHITE; DRAWTEXT_FIX(T11,0.76,TS11,0,'★操作风险提示:杀跌空仓'),COLORGREEN; DRAWTEXT_FIX(T12,0.36,TS12,0,'☆特别信号提示:筑底散兵坑'),COLOR66FFCC;DRAWTEXT_FIX(T13,0.36,TS13,0,'☆特别信号提示:铸顶风险区'),COLORCYAN; DRAWTEXT_FIX(T14,0.36,TS14,0,'☆特别信号提示:穿越主力'),COLORRED; DRAWTEXT_FIX(T15,0.36,TS15,0,'☆特别信号提示:穿越主力'),COLORYELLOW;DRAWTEXT_FIX(T16,0.36,TS16,0,'☆特别信号提示:穿越散户'),COLORGREEN;DRAWTEXT_FIX(T17,0.36,TS17,0,'☆特别信号提示:全盘穿越'),COLOR3399FF;。
通达信指标公式源码主力动向副图(主买主卖副图) 傻买傻卖公式
DRAWRECTREL(0,0,400,988,IF(120,RGB(10,0,0),0));超B:=L2_AMO(0,2)/10000.0;大B:=L2_AMO(1,2)/10000.0;中B:=L2_AMO(2,2)/10000.0;小B:=L2_AMO(3,2)/10000.0;超S:=L2_AMO(0,3)/10000.0;大S:=L2_AMO(1,3)/10000.0;中S:=L2_AMO(2,3)/10000.0;小S:=L2_AMO(3,3)/10000.0;主买A:=ACTINVOL,COLORRED,NODRAW;主卖A:=ACTOUTVOL,COLORGREEN,NODRAW;主买:=主买A*100/(主买A+主卖A),NODRAW,COLORRED;主卖:=主卖A*100/(主买A+主卖A),NODRAW,COLORGREEN;SAT:=(AMOUNT/C)/(HHV(AMOUNT,20)/HHV(C,20));【量能饱和】:IF(SAT>1,1,SAT)*100,COLORYELLOW,NODRAW;主力净买量:=(LARGEINTRDVOL-LARGEOUTTRDVOL),COLORYELLOW,NODRAW;大宗净流入:=(超B+大B)-(超S+大S),COLORRED,NODRAW;主动买卖差:=(ACTINVOL-ACTOUTVOL),COLORMAGENTA,NODRAW;主力资金差:=((L2_AMO(0,0)+L2_AMO(1,0)-L2_AMO(0,1)-L2_AMO(1,1)))/10000,COLORCYAN,NO DRAW;DRAWRECTREL(100,0,90+CONST(主买*300/100),40,RGB(230,65,0)); DRAWRECTREL(100,60,90+CONST(主卖*300/100),100,RGB(0,104,0));DRAWRECTREL(100,120,390,160,RGB(0,0,100));DRAWRECTREL(100,120,90+CONST(【量能饱和】*300/100),160,RGB(250,104,0));大单动向:=(LARGEINTRDVOL-LARGEOUTTRDVOL)*10000/FINANCE(7),NODRAW;T1:=IF (大单动向>0 AND REF(大单动向,1)<0,1,0);T2:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)<0,2,T1);T3:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)<0,3,T2);T4:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)<0,4,T3);T5:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)<0,5,T4);T6:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)>0 AND REF(大单动向,6)<0,6,T5); T7:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)>0 AND REF(大单动向,6)>0 AND REF(大单动向,7)<0,7,T6);T8:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)>0 AND REF(大单动向,6)>0 AND REF(大单动向,7)>0 AND REF(大单动向,8)<0,8,T7);T9:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)>0 AND REF(大单动向,6)>0 AND REF(大单动向,7)>0 AND REF(大单动向,8)>0 AND REF(大单动向,9)<0,9,T8);T:=IF (大单动向>0 AND REF(大单动向,1)>0 AND REF(大单动向,2)>0 AND REF(大单动向,3)>0 AND REF(大单动向,4)>0 AND REF(大单动向,5)>0 AND REF(大单动向,6)>0 AND REF(大单动向,7)>0 AND REF(大单动向,8)>0 AND REF(大单动向,9)>0,10,T9);D:=COUNT(大单动向>0,10),NODRAW;DRAWTEXT_FIX(1,0.005,0.01,0,STRCAT(STRCAT('【主买比】: ',CON2STR(主买,1)),' %')),COLORYELLOW;DRAWTEXT_FIX(1,0.005,0.07,0,STRCAT(STRCAT('【主卖比】: ',CON2STR(主卖,1)),' %')),COLORGREEN;DRAWTEXT_FIX(1,0.005,0.13,0,STRCAT(STRCAT('【量能饱和】: ',CON2STR(【量能饱和】,1)),' %')),COLORYELLOW;DRAWTEXT_FIX(1,0.005,0.19,0,STRCAT(STRCAT('【主力资金差】: ',CON2STR(主力资金差,1)),' 万元')),COLORYELLOW;DRAWTEXT_FIX(1,0.2,0.19,0,STRCAT(STRCAT('【大宗净流入】: ',CON2STR(大宗净流入,1)),' 万元')),COLORYELLOW;DRAWTEXT_FIX(1,0.005,0.25,0,STRCAT(STRCAT('【主力净买量】: ',CON2STR(主力净买量,1)),' 手')),COLORYELLOW;DRAWTEXT_FIX(1,0.2,0.25,0,STRCAT(STRCAT('【主动买卖差】: ',CON2STR(主动买卖差,1)),' 手')),COLORYELLOW;DRAWTEXT_FIX(1,0.005,0.31,0,STRCAT(STRCAT('【DDX 连红天数】: ',CON2STR(T,0)),' 天')),COLORYELLOW;DRAWTEXT_FIX(1,0.2,0.31,0,STRCAT(STRCAT('【DDX两周红天数】: ',CON2STR(D,0)),' 天')),COLORYELLOW;PJJ:=DMA((((HIGH + LOW) + (CLOSE * 2)) / 4),0.9);JJ:=REF(EMA(PJJ,3),1);QJJ:=(VOL / (((HIGH - LOW) * 2) - ABS((CLOSE - OPEN))));XVL:=(IF((CLOSE > OPEN),(QJJ * (HIGH - LOW)),IF((CLOSE < OPEN),(QJJ * ((HIGH - OPEN) + (CLOSE - LOW))),(VOL / 2))) + IF((CLOSE > OPEN),(0 - (QJJ * ((HIGH - CLOSE) + (OPEN - LOW)))),IF((CLOSE < OPEN),(0 - (QJJ * (HIGH - LOW))),(0 - (VOL / 2))))); ZLL:=(VOL / CAPITAL);HSL1:=IF((ZLL > 10),10,ZLL);HSL:=((XVL / 20) / 1.15);攻击流量:=(((HSL * 0.55) + (REF(HSL,1) * 0.33)) + (REF(HSL,2) * 0.22));GJJ:=EMA(攻击流量,8);LLJX:=EMA(攻击流量,3);STICKLINE(((HSL * 0.4) >= 0),((HSL * 0.4) +LLJX),0,3,0),COLOR00FFFF; STICKLINE(((HSL * 0.4) < 0),((HSL * 0.4) +LLJX),0,3,0),COLOR00FF00;资金流入:=IF((HSL*0.4+LLJX)>0,(HSL*0.4+LLJX),DRAWNULL),COLORRED;资金流出:=IF((HSL*0.4+LLJX)<0,(HSL*0.4+LLJX),DRAWNULL),COLOR00FF00;资金进出:=(HSL*0.4+LLJX),LINETHICK0;万元:=AMOUNT/10000{0000},VOLSTICK,COLORFF00FF;资金净进出:IF((HSL*0.4+LLJX)>0,资金流入,资金流出),COLORWHITE,POINTDOT;进出比例%:IF((HSL*0.4+LLJX)>0,资金流入/万元*100,资金流出/万元*100),COLORYELLOW;连红天1:=BARSLASTCOUNT(资金净进出>0),,COLORA20FFD,NODRAW;连红天2:=IF(连红天1=0,REF(连红天1,1),连红天1),,COLORA20FFD,NODRAW;连红天3:=IF(连红天2=0,REF(连红天1,2),连红天2),,COLORA20FFD,NODRAW;连红天4:=IF(连红天3=0,REF(连红天1,3),连红天3),,COLORA20FFD,NODRAW;近期连红天:IF(连红天4=0,REF(连红天1,4),连红天4),,COLORYELLOW,NODRAW;最多连红天1:=MAX(REF(近期连红天,1),近期连红天),COLORYELLOW,NODRAW;最多连红天2:=MAX(最多连红天1,REF(近期连红天,2)),COLORYELLOW,NODRAW;最多连红天3:=MAX(最多连红天2,REF(近期连红天,3)),COLORYELLOW,NODRAW;最多连红天4:=MAX(最多连红天3,REF(近期连红天,4)),COLORYELLOW,NODRAW;最多连红天5:=MAX(最多连红天4,REF(近期连红天,5)),COLORYELLOW,NODRAW;最多连红天:MAX(最多连红天5,REF(近期连红天,6)),COLORYELLOW,NODRAW;三日资金:SUM(资金进出,3),COLORWHITE,NODRAW;五日资金:SUM(资金进出,5),COLORFF00FF,NODRAW;十日资金:SUM(资金进出,10),COLOR0000FF,NODRAW;资金流量:=LLJX,LINETHICK0,COLOR0000FF;STICKLINE((资金流量> 0),资金流量,0,3,0),COLOR0000FF;STICKLINE((资金流量< 0),资金流量,0,3,0),COLORFF3300;黄柱初出蓝:=REF(资金流出,1)<0 AND 资金流入>30 AND C>O AND C>REF(C,1) AND C>MA(C,3);X:=(3*C+2*L+O+H)/7;多空线:=(20*X+19*REF(X,1)+18*REF(X,2)+17*REF(X,3)+16*REF(X,4)+15*REF(X,5)+14*REF(X,6)+13*REF(X,7)+12*REF(X,8)+11*REF(X,9)+10*REF(X,10)+9*REF(X,11)+8*REF(X,12)+7*REF(X,13)+6*REF(X,14)+5*REF(X,15)+4*REF(X,16)+3*REF(X,17)+2*REF(X,18)+ REF(X,20))/210;长黄柱:= 资金流入>300 AND CROSS(C,多空线);DRAWTEXT(黄柱初出蓝,-30,'★'),COLORFF00FF;DRAWTEXT(长黄柱,((HSL * 0.4) * 1.5)*1.4 ,'★'),COLORRED;ARE4:=MA(C,20); ARE5:=(C>MA(C,5)); ARE6:=(MA(C,5)>MA(C,10)); ARE7:=(C>MA(C,10));ARE8:=(MA(C,5)>MA(C,20)); ARE9:=(C>MA(C,20)); ARE10:=REF(ARE4,1); ARE11:=(ARE4>ARE10);AVX:=(((((IF(ARE5,10,(0-10))+IF(ARE6,10,(0-10)))+IF(ARE7,10,(0-10)))+IF(ARE8,10,(0 -10)))+IF(ARE9,10,(0-10)))+IF(ARE11,10,(0-10)));DSLX:=(C/INDEXC); DSLX1:=MA(DSLX,5); DSLX2:=MA(DSLX,10); VRE1:=MA(V,5); VRE2:=MA(V,10);阻力位:=IF((C>200),(C*1.01),(C*1.07)); 阻力位1:=IF((C<10),(C*1.05),阻力位);止损位:=IF((C>200),(C*0.99),(C*0.93)); 止损位1:=IF((C<10),(C*0.95),止损位); TJTS1:=ISLASTBAR AND C<500; TJTS2:=ISLASTBAR AND C>500;KDAT:=REFDATE(HHV(H,45)/0.097,DATE);{解盘位置}解盘1:=CONST(IF(TJTS1 AND ((CROSS(AVX,1) AND (VRE1 >= VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘2:=CONST(IF(TJTS1 AND ((CROSS(AVX,1) AND (VRE1 < VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘3:=CONST(IF(TJTS1 AND ((CROSS(AVX,1) AND (VRE1 > VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘4:=CONST(IF(TJTS1 AND ((CROSS(AVX,1) AND (VRE1 <= VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘5:=CONST(IF(TJTS1 AND ((CROSS(1,AVX) AND (VRE1 >= VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘6:=CONST(IF(TJTS1 AND ((CROSS(1,AVX) AND (VRE1 < VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘7:=CONST(IF(TJTS1 AND ((CROSS(1,AVX) AND (VRE1 >= VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘8:=CONST(IF(TJTS1 AND ((CROSS(1,AVX) AND (VRE1 < VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘9:=CONST(IF(TJTS1 AND ((((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 >= VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘10:=CONST(IF(TJTS1 AND ((((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 < VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘11:=CONST(IF(TJTS1 AND ((((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 >= VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘12:=CONST(IF(TJTS1 AND ((((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 < VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘13:=CONST(IF(TJTS1 AND ((((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 >=VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘14:=CONST(IF(TJTS1 AND ((((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 < VRE2)) AND (DSLX >= DSLX1)) ,1,0));解盘15:=CONST(IF(TJTS1 AND ((((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 >= VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘16:=CONST(IF(TJTS1 AND ((((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 < VRE2)) AND (DSLX < DSLX1)) ,1,0));解盘17:=CONST(IF(TJTS2 AND (CROSS(AVX,1) AND (VRE1 >= VRE2)) ,1,0));解盘18:=CONST(IF(TJTS2 AND (CROSS(AVX,1) AND (VRE1 >= VRE2)) ,1,0));解盘19:=CONST(IF(TJTS2 AND (CROSS(AVX,1) AND (VRE1 < VRE2)) ,1,0));解盘20:=CONST(IF(TJTS2 AND (CROSS(AVX,1) AND (VRE1 < VRE2)) ,1,0));解盘21:=CONST(IF(TJTS2 AND (CROSS(1,AVX) AND (VRE1 >= VRE2)) ,1,0));解盘22:=CONST(IF(TJTS2 AND (CROSS(1,AVX) AND (VRE1 < VRE2)) ,1,0));解盘23:=CONST(IF(TJTS2 AND (((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 >= VRE2)) ,1,0));解盘24:=CONST(IF(TJTS2 AND (((AVX >= 1) AND (REF(AVX,1) > 0)) AND (VRE1 < VRE2)) ,1,0));解盘25:=CONST(IF(TJTS2 AND (((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 >= VRE2)) ,1,0));解盘26:=CONST(IF(TJTS2 AND (((AVX < 1) AND (REF(AVX,1) < 0)) AND (VRE1 < VRE2)) ,1,0));解盘文字1:=IF(解盘1=1,'该股的量能理想,有明显走强迹象,可以考虑中线进场参与,仓位在2/3左右',IF(解盘2=1,'该股虽然走势趋强,但量能还显不足,可以考虑短线进场,仓位在1/2左右', IF(解盘3=1,'该股量价配合良好,但相对其它股票并没有明显走强,可以考虑短线进场,仓位1/2左右',IF(解盘4=1,'该股形态尚可,但量能不足,股票也未完全走强,可以短线参与,仓位1/3左右',IF(解盘5=1,'该股形态变坏,但走势相对其它股票尚可,重仓者减持大半,清仓者可以观望',IF(解盘6=1,'该股随大盘一起下跌,程明显缩量走势,考虑到大盘风险,减持或清仓',IF(解盘7=1,'该股放量下跌,走势明显偏弱,离场观望',IF(解盘8=1,'该股缩量下跌,走势偏弱,离场观望',IF(解盘9=1,'该股形态良好,强势明显,量能充足,可以继续持有',IF(解盘10=1,'该股上行趋势不变,强势依然,但量能开始转弱,注意风险',IF(解盘11=1,'该股仍然具备上涨潜力,但股性偏弱,可考虑减仓',IF(解盘12=1,'该股走势趋弱,量能不足,减持大部分筹码',IF(解盘13=1,'该股形态不佳,注意成交量的变化,但目前不适合参与',IF(解盘14=1,'该股趋势不明,股价偏弱,注意量能变化,目前不宜参与',IF(解盘15=1,'该股有走强迹象,但量能不足,趋势不明,不适合操作',IF(解盘17=1,'大盘量能理想,有明显走强迹象,可以考虑中线进场参与,仓位在2/3左右',IF(解盘19=1,'大盘虽然走势趋强,但量能还显不足,如果前期经过一轮下跌',IF(解盘21=1,'大盘形态走坏,重仓者可以减去大部分仓位',IF(解盘22=1,'大盘缩量调整,注意风险,短线清仓观望',IF(解盘23=1,'大盘走势良好,量能理想,可以继续持有强势股',IF(解盘24=1,'大盘形态良好,但量能稍显不足,随时准备减仓',IF(解盘25=1,'大盘趋势不明,注意成交量变化,目前不适宜进场',IF(解盘26=1,'大盘趋势向下,量能萎缩,不适合进场',DRAWNULL)))))))))))))))))))))));解盘文字2:=IF(解盘16=1,'该股走势太弱,没有参与价值',IF(解盘18=1,' 如前期经过一轮下跌,此时为最佳买点,但如果前期有过一段涨幅则介入需谨慎',IF(解盘20=1,' 可以考虑短线进场,仓位在1/2左右,一旦量能放大可以加仓买入',DRAWNULL)));DRAWTEXT(CURRBARSCOUNT=70{位置} AND (解盘1=1 OR 解盘2=1 OR 解盘3=1 OR 解盘4=1 OR 解盘5=1 OR 解盘6=1 OR 解盘7=1 OR解盘8=1 OR 解盘9=1 OR 解盘10=1 OR 解盘11=1 OR 解盘12=1 OR 解盘13=1 OR 解盘14=1 OR 解盘15=1 OR 解盘17=1 OR解盘19=1 OR 解盘21=1 OR 解盘22=1 OR 解盘23=1 OR 解盘24=1 OR 解盘25=1 OR 解盘26=1),(KDAT*0.99),解盘文字1),COLOR00FFFF;DRAWTEXT(CURRBARSCOUNT=70{位置} AND (解盘16=1 OR 解盘18=1 OR 解盘20=1),IF(解盘18=1 OR 解盘20=1,KDAT*0.98,KDAT*0.96),解盘文字2),COLOR00FFFF; TT:=240/FROMOPEN;比:=TT;促进指数MFL:=(HIGH-LOW)*1000000/(VOL*比),COLORRED;AY2:=EMA(CLOSE,12)-EMA(CLOSE,26);AZ2:=EMA(AY2,9);LT2:=(AY2-AZ2);L211:=IF(LT2,LLV(L,21),DRAWNULL),COLOR217158,CIRCLEDOT;ZGD:=HHV(H,80)*0.99;ZGD2:=CONST(ZGD);ZDD:=LLV(L211,80);ZDD2:=CONST(ZDD);YYA4:=MA(CLOSE,20);YYA5:=(CLOSE > MA(CLOSE,5));YYA6:=(MA(CLOSE,5) > MA(CLOSE,10));YYA7:=(CLOSE > MA(CLOSE,10));YYA8:=(MA(CLOSE,5) > MA(CLOSE,20));YYA9:=(CLOSE > MA(CLOSE,20));YYA10:=REF(YYA4,1);YYA11:=(YYA4 > YYA10);YYAVX:=(((((IF(YYA5,10,(0 - 10)) + IF(YYA6,10,(0 - 10))) + IF(YYA7,10,(0 - 10))) + IF(YYA8,10,(0 - 10))) + IF(YYA9,10,(0 - 10))) + IF(YYA11,10,(0 - 10)));YYV1:=MA(VOL,5);YYV2:=MA(VOL,10);J1:=CONST(IF( YYAVX > 0,200,100));J2:=CONST(IF( YYAVX > 0,00,100));J3:=CONST(IF( YYAVX > 0,100,100));WJ:=(H+L+C)/3;VV1:=IF(H=L,1,H-MAX(O,C));VV2:=IF(H=L,1,MAX(C,O)-WJ);VV3:=IF(H=L,1,MIN(O,C)-L);V4:=IF(H=L,1,WJ-MIN(C,O));VV5:=VOL/IF(H=L,4,H-L);V6:=(VV1*VV5);V7:=(VV2*VV5);V8:=(VV3*VV5);V9:=(V4*VV5);买盘1:=DYNAINFO(23)*比;卖盘1:=DYNAINFO(22)*比;买盘2:=IF(ISLASTBAR AND C>300,(V9+V8)*TT,(V9+V8));卖盘2:=IF(ISLASTBAR AND C>300,(V6+V7)*TT,(V6+V7));买盘:=IF(ISLASTBAR AND PERIOD=5 AND C<300,买盘1,买盘2);卖盘:=IF(ISLASTBAR AND PERIOD=5 AND C<300,卖盘1,卖盘2);{买卖差:=买盘-卖盘;}MFI:=(HIGH-LOW)*1000000/(VOL*比);绿灯:=MFI>=REF(MFI,1)AND VOL*比>=REF(VOL,1);M1:=CONST(绿灯);衰退:=MFI<REF(MFI,1)AND VOL*比<REF(VOL,1);M2:=CONST(衰退);伪装:=MFI>=REF(MFI,1)AND VOL*比<REF(VOL,1);M3:=CONST(伪装);蛰伏:=MFI<REF(MFI,1)AND VOL*比>=REF(VOL,1);M4:=CONST(蛰伏);量大:=(卖盘+买盘)/REF(VOL,1)>2;M5:=CONST(量大);量缩:=REF(VOL,1)/(卖盘+买盘)>1.5;M6:=CONST(量缩);卖量大:=(卖盘-买盘)/买盘>0.4;M7:=CONST(卖量大);买量大:=(买盘-卖盘)/卖盘>0.4;M8:=CONST(买量大);TS1:=IF(M1=1,1.99+4.99,0.91);TS2:=IF(M2=1,TS1+4.99,TS1);TS3:=IF(M3=1,TS2+4.99,TS2);TS4:=IF(M4=1,TS3+4.99,TS3);TS5:=IF(M5=1,TS4+4.99,TS4);TS6:=IF(M6=1,TS5+4.99,TS5);TS7:=IF(M7=1,TS6+4.99,TS6);TS8:=IF(M8=1,TS7+4.99,TS7);DRAWTEXT(M1 AND CURRBARSCOUNT=50,ZGD2-(ZGD2*TS1),'[绿灯]实计交易量增加。
通达信自编图表资金流副图源码
通达信自编图表资金流副图源码以下是通达信自编图表资金流副图源码(无源码的请下载附件导入)通达信自编图表资金流副图源码主力bbd:=(BIGORDER(1)-BIGORDER(2))*AMOUNT/10000;超大bbd:=(BIGORDER(1,3)-BIGORDER(2,3))*AMOUNT/10000;大户bbd:=主力bbd-超大bbd;中户bbd:=(BIGORDER(1,1)-BIGORDER(2,1))*AMOUNT/10000-主力bbd;散户bbd:=((1-BIGORDER(1,1))-(1-BIGORDER(2,1)))*AMOUNT/10000;占比1:=(BIGORDER(1)-BIGORDER(2));占比2:=(BIGORDER(1)-BIGORDER(2))*AMOUNT/(CAPITAL*c);DRAWTEXTREL(15,710,'总股本:'+NUMTOSTRn(FINANCE2(35),0)+'万股' +' 流通A 股:'+NUMTOSTRn(FINANCE2(37),0)+'万股'+' 每股收益:'+NUMTOSTRN(FINANCE2(3),3)+'元'+' 市盈率:'+NUMTOSTRN(DYNAINFO(39),2)+' 市净率:'+NUMTOSTRN((CLOSE / FINANCE2(4)),2)+' 主营收入同比增长:'+NUMTOSTRN(FINANCE2(11),2)+'%'+' 净利润同比增长:'+NUMTOSTRN(FINANCE2(10),2)+'%'),Color0088FF;DRAWTEXTREL(80,25,' Superviiew资金流向'),ColorFFFF00,LINETHICK3;DRAWTEXTREL(410,25,' '+STKLABEL),ColorWHITE,LINETHI CK3;DRAWTEXTREL(310,25,' '+STKNAME),ColorRED,LINETHICK 3;DRAWTEXTREL(550,30,' 所属版块: '+BKNAME),Color555FFF;DRAWTEXTREL(115,99,' 日期'),ColorRED;DRAWTEXTREL(144,139,'月'+DAY),ColorEEFF00;DRAWTEXTREL(125,139,'年'+MONTH),ColorEEFF00;DRAWTEXTREL(95,139,' '+YEAR),ColorEEFF00;DRAWTEXTREL(170,139,'日'),ColorEEFF00;DRAWTEXTREL(115,189,'前一交易日 '),Color55FF55;DRAWTEXTREL(115,239,'前二交易日'),Color55EE00;DRAWTEXTREL(115,289,'前三交易日'),Color55FF00;DRAWTEXTREL(115,339,'前四交易日'),Color55FF00;DRAWTEXTREL(115,389,'SV 5日统计'),Color555FFF,LINETHICK2;DRAWTEXTREL(115,439,'SV10日统计'),Color555FFF,LINETHICK2;DRAWTEXTREL(115,489,'SV20日统计'),Color555FFF,LINETHICK2;DRAWTEXTREL(245,99,'散户净流入(万元)'),Color555FFF;DRAWTEXTREL(365,99,'中户净流入(万元)'),Color555FFF;DRAWTEXTREL(485,99,'大户净流入(万元)'),Color555FFF;DRAWTEXTREL(605,99,'超大户净流入(万元)'),Color555FFF;DRAWTEXTREL(735,99,'主力净流入(万元)'),Color555FFF;DRAWTEXTREL(875,99,'占总成交额比(%)'),Color555FFF;DRAWTEXTREL(1000,99,'占流通市值比(%)'),Color555FFF;DRAWTEXTREL(85,69,'────────────────────────────────────────────────────────────────────────────────────'),ColorRED;DRAWTEXTREL(245,139,' '+散户bbd),Color208FFF;DRAWTEXTREL(365,139,' '+中户bbd),Color208FFF;DRAWTEXTREL(485,139,' '+大户bbd),Color208FFF;DRAWTEXTREL(605,139,' '+超大bbd),Color208FFF;DRAWTEXTREL(735,139,' '+主力bbd),Color208FFF;DRAWTEXTREL(875,139,' '+占比1),Color208FFF; DRAWTEXTREL(1000,139,' '+占比2),Color208FFF; DRAWTEXTREL(245,189,' '+REF(散户bbd,1)),Color208FFF; DRAWTEXTREL(365,189,' '+REF(中户bbd,1)),Color208FFF; DRAWTEXTREL(485,189,' '+REF(大户bbd,1)),Color208FFF; DRAWTEXTREL(605,189,' '+REF(超大bbd,1)),Color208FFF; DRAWTEXTREL(735,189,' '+REF(主力bbd,1)),Color208FFF; DRAWTEXTREL(875,189,' '+REF(占比1,1)),Color208FFF; DRAWTEXTREL(1000,189,' '+REF(占比2,1)),Color208FFF; DRAWTEXTREL(245,239,' '+REF(散户bbd,2)),Color208FFF; DRAWTEXTREL(365,239,' '+REF(中户bbd,2)),Color208FFF; DRAWTEXTREL(485,239,' '+REF(大户bbd,2)),Color208FFF; DRAWTEXTREL(605,239,' '+REF(超大bbd,2)),Color208FFF; DRAWTEXTREL(735,239,' '+REF(主力bbd,2)),Color208FFF; DRAWTEXTREL(875,239,' '+REF(占比1,2)),Color208FFF; DRAWTEXTREL(1000,239,' '+REF(占比2,2)),Color208FFF; DRAWTEXTREL(245,289,' '+REF(散户bbd,3)),Color208FFF; DRAWTEXTREL(365,289,' '+REF(中户bbd,3)),Color208FFF; DRAWTEXTREL(485,289,' '+REF(大户bbd,3)),Color208FFF; DRAWTEXTREL(605,289,' '+REF(超大bbd,3)),Color208FFF; DRAWTEXTREL(735,289,' '+REF(主力bbd,3)),Color208FFF; DRAWTEXTREL(875,289,' '+REF(占比1,3)),Color208FFF; DRAWTEXTREL(1000,289,' '+REF(占比2,3)),Color208FFF; DRAWTEXTREL(245,339,' '+REF(散户bbd,4)),Color208FFF; DRAWTEXTREL(365,339,' '+REF(中户bbd,4)),Color208FFF; DRAWTEXTREL(485,339,' '+REF(大户bbd,4)),Color208FFF; DRAWTEXTREL(605,339,' '+REF(超大bbd,4)),Color208FFF; DRAWTEXTREL(735,339,' '+REF(主力bbd,4)),Color208FFF; DRAWTEXTREL(875,339,' '+REF(占比1,4)),Color208FFF; DRAWTEXTREL(1000,339,' '+REF(占比2,4)),Color208FFF;DRAWTEXTREL(365,389,' '+SUM(中户bbd,5)),Color208FFF;DRAWTEXTREL(485,389,' '+SUM(大户bbd,5)),Color208FFF;DRAWTEXTREL(605,389,' '+SUM(超大bbd,5)),Color208FFF;DRAWTEXTREL(735,389,' '+SUM(主力bbd,5)),Color208FFF;DRAWTEXTREL(875,389,' '+SUM(占比1,5)),Color208FFF;DRAWTEXTREL(1000,389,' '+SUM(占比2,5)),Color208FFF;DRAWTEXTREL(245,439,' '+SUM(散户bbd,10)),Color208FFF;DRAWTEXTREL(365,439,' '+SUM(中户bbd,10)),Color208FFF;DRAWTEXTREL(485,439,' '+SUM(大户bbd,10)),Color208FFF;DRAWTEXTREL(605,439,' '+SUM(超大bbd,10)),Color208FFF;DRAWTEXTREL(735,439,' '+SUM(主力bbd,10)),Color208FFF;DRAWTEXTREL(875,439,' '+SUM(占比1,10)),Color208FFF;DRAWTEXTREL(1000,439,' '+SUM(占比2,10)),Color208FFF;DRAWTEXTREL(245,489,' '+SUM(散户bbd,20)),Color208FFF;DRAWTEXTREL(365,489,' '+SUM(中户bbd,20)),Color208FFF;DRAWTEXTREL(485,489,' '+SUM(大户bbd,20)),Color208FFF;DRAWTEXTREL(605,489,' '+SUM(超大bbd,20)),Color208FFF;DRAWTEXTREL(735,489,' '+SUM(主力bbd,20)),Color208FFF;DRAWTEXTREL(875,489,' '+SUM(占比1,20)),Color208FFF;。
看清主力资金副图源码通达信指标公式源码
ZLCM:=EMA(WINNER(CLOSE)*70,3);SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3); ZSHTL:=SHCM/(ZLCM+SHCM)*100;ZZLKP:=ZLCM/(ZLCM+SHCM)*100;ZCMZL:=MA(ZLCM+SHCM,13);ZZNTS:=BARSLAST(ZSHTL<90 AND REF(ZSHTL,1)>90);ZSHJJ:=EMA(ZSHTL,89);ZZLJJ:=EMA(ZZLKP,89);ZJLRQD:=INTPART(ZZLKP-ZZLJJ);SH8:=EMA(ZSHTL,8);DKB:=IF(ZZLKP-REF(ZZLKP,1)>ZSHTL-REF(ZSHTL,1),1,0);STICKLINE(REF(ZSHTL,1)>90 AND ZSHTL<90,ZSHTL,0,4,0),COLOR9966FF; STICKLINE(C>0,ZSHTL,ZZLKP,0,0),COLOREEEEEE;STICKLINE(ZSHJJ>REF(ZSHJJ,1),ZSHTL,ZSHJJ,1,0),COLORAAAAAA; STICKLINE(C>0,ZZLKP,0,3,0),COLORBLUE;STICKLINE(ZZLKP>75,ZZLKP,0,3,0),COLORFFFFFF;STICKLINE(ZZLJJ>REF(ZZLJJ,1),ZZLKP,ZZLJJ,3,0),COLORRED; STICKLINE(ZSHTL>=90,ZZLKP,0,3,0),COLORYELLOW;散户套牢系数:INTPART(ZSHTL),NODRAW;主力控盘系数:INTPART(ZZLKP),COLORCYAN,NODRAW;资金流入强度:ZJLRQD,NODRAW;RSV:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;K1:=SMA(RSV,10,1);D1:=SMA(K1,5,1);KK:=INTPART(K1);DD:=INTPART(D1);TFXXS:=KK+DD;TGLD:=MOD(TFXXS,10);TGLXS:=(TFXXS-REF(TFXXS,1))*10;TYCFX:=TFXXS+TGLXS;乖离系数:TGLXS,NODRAW,COLORGREEN;STICKLINE(TGLXS>0,150,150+TGLXS,3,0),COLOR000088;STICKLINE(TGLXS>0,150,150+TGLXS,2.5,0),COLOR000099;STICKLINE(TGLXS>0,150,150+TGLXS,2,0),COLOR0000AA;STICKLINE(TGLXS>0,150,150+TGLXS,1.5,0),COLOR0000BB;STICKLINE(TGLXS>0,150,150+TGLXS,1.0,0),COLOR0000DD;STICKLINE(TGLXS>0,150,150+TGLXS,0.5,0),COLOR0000FF;STICKLINE(TGLXS<0,150,150+TGLXS,3,0),COLOR008800;STICKLINE(TGLXS<0,150,150+TGLXS,2.5,0),COLOR00AA00;STICKLINE(TGLXS<0,150,150+TGLXS,2,0),COLOR00BB00;STICKLINE(TGLXS<0,150,150+TGLXS,1.5,0),COLOR00DD00;STICKLINE(TGLXS<0,150,150+TGLXS,1,0),COLOR00FF00;STICKLINE(TGLXS=0 AND REF(TGLXS,1)>=0,150,150+TGLXS,8,0),COLORRED; STICKLINE(TGLXS=0 AND REF(TGLXS,1)<0,150,150+TGLXS,8,0),COLORGREEN;风险系数:TFXXS,LINETHICK2,COLORYELLOW;预测风险:TYCFX,LINETHICK1,COLORCYAN;市场筹码总量:ZCMZL,COLORGREEN,LINETHICK1;上市:FINANCE(42)/10000,NODRAW,COLORYELLOW;STICKLINE(TGLXS>0 AND 100+TGLXS<TYCFX AND 100+REF(TGLXS,1)>=REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLOW; STICKLINE(TGLXS<0 AND 100+TGLXS>=TYCFX AND 100+REF(TGLXS,1)<REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLOW;T1:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=1);T2:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=0);T3:=CONST( ZCMZL=REF(ZCMZL,1));T4:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=1);T5:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=0);T6:=CONST(TFXXS<=50 );T7:=CONST(TFXXS>=160 );T8:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS<=100 );T9:=CONST( TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS>100); T10:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) AND TFXXS>100 ); T11:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) ANDTFXXS<=100 );T12:=CONST( ZSHTL>90 );T13:=CONST( ZZLKP>75 );T14:=CONST(CROSS(ZCMZL,ZZLJJ) AND ZZLKP>ZZLJJ AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T15:=CONST(CROSS(ZCMZL,ZZLKP) AND ZZLKP>ZZLJJ AND ZZLKP<ZSHTL AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T16:=CONST( CROSS(ZCMZL,ZSHTL) AND ZSHTL>ZZLKP AND ZCMZL>REF(ZCMZL,1)); T17:=CONST( CROSS(ZCMZL,100) AND ZCMZL>REF(ZCMZL,1));T18:=CONST(REF(ZSHTL,1)>90 AND ZSHTL<90 );TS1:=IF(T1=1,0+0.03,0);TS2:=IF(T2=1,TS1+0.03,TS1);TS3:=IF(T3=1,TS2+0.03,TS2);TS4:=IF(T4=1,TS3+0.03,TS3);TS5:=IF(T5=1,TS4+0.03,TS4);TS6:=IF(T6=1,0+0.73,0);TS7:=IF(T7=1,TS6+0.03,TS6);TS8:=IF(T8=1,TS7+0.03,TS7);TS9:=IF(T9=1,TS8+0.03,TS8);TS10:=IF(T10=1,TS9+0.03,TS9);TS11:=IF(T11=1,TS10+0.03,TS10);TS12:=IF(T12,0+0.03,0);TS13:=IF(T13=1,TS12+0.03,TS12);TS14:=IF(T14=1,TS13+0.03,TS13);TS15:=IF(T15=1,TS14+0.03,TS14);TS16:=IF(T16=1,TS15+0.03,TS15);TS17:=IF(T17=1,TS16+0.03,TS16);TS18:=IF(T8=1,TS17+0.03,TS17);DRAWTEXT_FIX(T1,0.58,TS1,0,'★主力动向监控:主力增仓'),COLORRED; DRAWTEXT_FIX(T2,0.58,TS2,0,'★主力动向监控:主力减仓'),COLORMAGENTA; DRAWTEXT_FIX(T3,0.58,TS3,0,'★主力动向监控:多空平衡'),COLORGRAY; DRAWTEXT_FIX(T4,0.58,TS4,0,'★主力动向监控:主力回补'),COLORFF9933; DRAWTEXT_FIX(T5,0.58,TS5,0,'★主力动向监控:主力出逃'),COLORGREEN; DRAWTEXT_FIX(T6,0.78,TS6,0,'★操作风险提示:买入风险'),COLORYELLOW; DRAWTEXT_FIX(T7,0.78,TS7,0,'★操作风险提示:卖出风险'),COLORCYAN; DRAWTEXT_FIX(T8,0.78,TS8,0,'★操作风险提示:追涨博弈'),COLORRED; DRAWTEXT_FIX(T9,0.78,TS9,0,'★操作风险提示:稳健持股'),COLORMAGENTA; DRAWTEXT_FIX(T10,0.76,TS10,0,'★操作风险提示:盘跌减仓'),COLORWHITE; DRAWTEXT_FIX(T11,0.76,TS11,0,'★操作风险提示:杀跌空仓'),COLORGREEN; DRAWTEXT_FIX(T12,0.36,TS12,0,'☆特别信号提示:筑底散兵坑'),COLOR66FFCC; DRAWTEXT_FIX(T13,0.36,TS13,0,'☆特别信号提示:铸顶风险区'),COLORCYAN; DRAWTEXT_FIX(T14,0.36,TS14,0,'☆特别信号提示:穿越主力'),COLORRED; DRAWTEXT_FIX(T15,0.36,TS15,0,'☆特别信号提示:穿越主力'),COLORYELLOW; DRAWTEXT_FIX(T16,0.36,TS16,0,'☆特别信号提示:穿越散户'),COLORGREEN;DRAWTEXT_FIX(T17,0.36,TS17,0,'☆特别信号提示:全盘穿越'),COLOR3399FF;。
最牛通达信量化副图指标公式源码
最牛通达信量化副图指标公式源码M1:=5;M2:=10;ZLCM:=EMA<WINNER<CLOSE>*70,3>;{//主力筹码估算} SHCM:=EMA<<WINNER<CLOSE*1.1>-WINNER<CLOSE* 0.9>>*80,3>;{//小筹码估算}ZSHTL:=SHCM/<ZLCM+SHCM>*100;{//小股民套牢筹码比率}ZZLKP:=ZLCM/<ZLCM+SHCM>*100;{//主力控盘筹码比率}ZCMZL:=MA<ZLCM+SHCM,13>;{//市场筹码总量} ZZNTS:=BARSLAST<ZSHTL90>;{//走牛天数}ZSHJJ:=EMA<ZSHTL,89>;{//小股民警戒}ZZLJJ:=EMA<ZZLKP,89>;{//主力警戒}ZJLRQD:=INTPART<ZZLKP-ZZLJJ>;{//资金流入强度}SH8:=EMA<ZSHTL,8>;DKB:=IF<ZZLKP-REF<ZZLKP,1>>ZSHTL-REF<ZSHTL,1>, 1,0>;{//------[数值显示]}散户套牢系数:INTPART<ZSHTL>,NODRAW;主力控盘系数:INTPART<ZZLKP>,COLOR4080FF,NODRAW;资金流入强度:ZJLRQD,NODRAW,COLOR00FFFF;{☆精确风险}{[参数定义]}RSV:=<CLOSE-LLV<LOW,15>>/<HHV<HIGH,15>-LLV<LO W,15>>*100;K1:=SMA<RSV,10,1>;D1:=SMA<K1,5,1>;KK:=INTPART<K1>;DD0:=INTPART<D1>;TF##S:=KK+DD0;{//变异KD风险系数}TGLD:=MOD<TF##S,10>;{//踏浪涨停概率点}TGLXS:=<TF##S-REF<TF##S,1>>*10;{//变异KD乖离系数} TYCFX:=TF##S+TGLXS;{//变异KD预测风险}乖离系数:TGLXS,LINETHICK0,COLORGREEN,NODRAW; {[图解模板]}{级别拐点}{乖离系数}STICKLINE<TGLXS>0,100,100+TGLXS,3,0>,COLOR00008 8;STICKLINE<TGLXS>0,100,100+TGLXS,2.5,0>,COLOR0000 99;STICKLINE<TGLXS>0,100,100+TGLXS,2,0>,COLOR0000AA;STICKLINE<TGLXS>0,100,100+TGLXS,1.5,0>,COLOR0000 BB;{STICKLINE<TGLXS>0,100,100+TGLXS,1.2,0>,COLOR000 0CC;}STICKLINE<TGLXS>0,100,100+TGLXS,1.0,0>,COLOR0000 DD;{STICKLINE<TGLXS>0,100,100+TGLXS,0.8,0>,COLOR000 0EE;}STICKLINE<TGLXS>0,100,100+TGLXS,0.5,0>,COLOR0000 FF;{//红柱}STICKLINE<TGLXS<0,100,100+TGLXS,3,0>,COLOR00880 0;{STICKLINE<TGLXS<0,100,100+TGLXS,2.8,0>,COLOR009 900;}STICKLINE<TGLXS<0,100,100+TGLXS,2.5,0>,COLOR00A A00;STICKLINE<TGLXS<0,100,100+TGLXS,2,0>,COLOR00BB0 0;{STICKLINE<TGLXS<0,100,100+TGLXS,1.8,0>,COLOR00C C00;}STICKLINE<TGLXS=0,100,100+TGLXS,8,0>,COLORRED;STICKLINE<TGLXS=0 ANDREF<TGLXS,1>REF<ZCMZL,1> AND DKB=0>;T3:=CONST< ZCMZL=REF<ZCMZL,1>>;T4:=CONST< ZCMZL50 AND TF##S=REF<TF##S,1> AND TF##S>100>;T10:=CONST<TF##S>50 AND TF##S100 >;T11:=CONST<TF##S>50 AND TF##SREF<ZCMZL,1> >; T15:=CONST<CROSS<ZCMZL,ZZLKP> ANDZZLKP>ZZLJJ AND ZZLKP10 AND ZZLJJ>REF<ZZLJJ,1> AND ZCMZL>REF<ZCMZL,1> >;T16:=CONST< CROSS<ZCMZL,ZSHTL> ANDZSHTL>ZZLKP AND ZCMZL>REF<ZCMZL,1>>;T17:=CONST< CROSS<ZCMZL,100> ANDZCMZL>REF<ZCMZL,1>>;T18:=CONST<REF<ZSHTL,1>>90 AND ZSHTL<90 >;TS1:=IF<T1=1,0+0.03,0>;TS2:=IF<T2=1,TS1+0.03,TS1>;TS3:=IF<T3=1,TS2+0.03,TS2>;TS4:=IF<T4=1,TS3+0.03,TS3>;TS5:=IF<T5=1,TS4+0.03,TS4>;TS6:=IF<T6=1,0+0.73,0>;TS7:=IF<T7=1,TS6+0.03,TS6>;TS8:=IF<T8=1,TS7+0.03,TS7>;TS9:=IF<T9=1,TS8+0.03,TS8>;TS10:=IF<T10=1,TS9+0.03,TS9>;TS11:=IF<T11=1,TS10+0.03,TS10>;TS12:=IF<T12,0+0.03,0>;TS13:=IF<T13=1,TS12+0.03,TS12>;TS14:=IF<T14=1,TS13+0.03,TS13>;TS15:=IF<T15=1,TS14+0.03,TS14>;TS16:=IF<T16=1,TS15+0.03,TS15>;TS17:=IF<T17=1,TS16+0.03,TS16>;TS18:=IF<T8=1,TS17+0.03,TS17>;DRAWTEXT_FIX<T1,0.66,TS1,0,'★监控:主力增仓'>,COLOR8080FF;DRAWTEXT_FIX<T2,0.66,TS2,0,'★监控:主力减仓'>,COLORFFFF00;DRAWTEXT_FIX<T3,0.66,TS3,0,'★监控:多空平衡'>,COLORGRAY;DRAWTEXT_FIX<T4,0.66,TS4,0,'★监控:主力回补'>,COLORFF9933;DRAWTEXT_FIX<T5,0.66,TS5,0,'★监控:主力出逃'>,COLORFFFF00;DRAWTEXT_FIX<T6,0.86,TS6,0,'★操作:买入风险'>,COLORYELLOW;DRAWTEXT_FIX<T7,0.86,TS7,0,'★操作:卖出风险'>,COLORFFFF00;DRAWTEXT_FIX<T8,0.86,TS8,0,'★操作:追涨博弈'>,COLOR8080FF;DRAWTEXT_FIX<T9,0.86,TS9,0,'★操作:稳健持股'>,COLOR8080FF;DRAWTEXT_FIX<T10,0.86,TS10,0,'★操作:盘跌减仓'>,COLORFFFF00;DRAWTEXT_FIX<T11,0.86,TS11,0,'★操作:杀跌空仓'>,COLORFFFF00;DRAWTEXT_FIX<T12,0.36,TS12,0,'☆特别提示:筑底散兵坑'>,COLOR66FFCC;DRAWTEXT_FIX<T13,0.36,TS13,0,'☆特别提示:铸顶风险区'>,COLORFFFF00;DRAWTEXT_FIX<T14,0.36,TS14,0,'☆特别提示:穿越主力'>,COLOR8080FF;DRAWTEXT_FIX<T15,0.36,TS15,0,'☆特别提示:穿越主力'>,COLORYELLOW;DRAWTEXT_FIX<T16,0.36,TS16,0,'☆特别提示:穿越散户'>,COLORGREEN;DRAWTEXT_FIX<T17,0.36,TS17,0,'☆特别提示:全盘穿越'>,COLOR3399FF;DRAWTEXT_FIX<T18,0.36,TS18,0,'☆特别提示:神秘黑洞'>,COLOR9966FF;{AAA:=REFDATE<HHV<H,30>,DATE>;T1A:=CONST<IF<ZZNTS,1,0>>;TS1A:=IF<T1A=1,0+0.03,0>;}{DRAWTEXT<T1A=1 AND CURRBARSCOUNT=45 AND PERIOD=5,AAA-<AAA*TS1A>,'[走牛天数判断]'>,COLORRED,LINETHICK6;}{DRAWNUMBER<T1A=1 AND CURRBARSCOUNT=45-12 ANDPERIOD=5,AAA-<AAA*TS1A>,CONST<ZZNTS>>,COLOR RED,LINETHICK6;};三日最低:=EMA<<REF<L,4>+REF<L,3>+REF<L,2>>/3,3>; 三日最高:=EMA<<REF<H,4>+REF<H,3>+REF<H,2>>/3,3>,COLOR WHITE;高:=CROSS<CROSS<三日最高,C>,0.6>,STICK,COLORWHITE;DRAWICON<高>0,高,2>;F:=100*<C-REF<C,1>>/REF<C,1>;博尔:=IF<C0,P1=0,1>;量:V,VOLSTICK;PJJ:=DMA<<<<HIGH + LOW> + <CLOSE * 2>> / 4>,0.9>; JJ:=REF<EMA<PJJ,3>,1>;QJJ:=<VOL / <<<HIGH - LOW> * 2> - ABS<<CLOSE - OPEN>>>>; XVL:=<IF<<CLOSE > OPEN>,<QJJ * <HIGH - LOW>>,IF<<CLOSE OPEN>,<0 - <QJJ * <<HIGH - CLOSE> + <OPEN - LOW>>>>,IF<<CLOSE 10>,10,ZLL>;HSL:=<<XVL / 20> / 1.15>;进攻流量:=<<<HSL * 0.55> + <REF<HSL,1> * 0.33>> +<REF<HSL,2> * 0.22>>;GJJ:=EMA<进攻流量,8>; LLJX:=EMA<进攻流量,3>;动态天量:=CONST<IF<V=HHV<V,20>,V,REF<V,BARSLAST<V=H HV<V,20>>>>>,COLOR00FF00,POINTDOT;STICKLINE<<<HSL * 0.4> >= 0>,动态天量+<<HSL * 0.4> +LLJX>*20,动态天量,3,0>,COLORYELLOW; STICKLINE<<<HSL * 0.4>0,<HSL*0.4+LLJX>,DRAWNULL>,COLORRED;资金流出:=IF<<HSL*0.4+LLJX>0,资金流入,资金流出>,COLORWHITE,POINTDOT;收支比例%:IF<<HSL*0.4+LLJX>>0,资金流入/万元*100,资金流出/万元*100>,COLORYELLOW;连红天1:=BARSLASTCOUNT<资金净收支>0>,,COLORA20FFD,NODRAW;连红天2:=IF<连红天1=0,REF<连红天1,1>,连红天1>,,COLORA20FFD,NODRAW;连红天3:=IF<连红天2=0,REF<连红天1,2>,连红天2>,,COLORA20FFD,NODRAW;连红天4:=IF<连红天3=0,REF<连红天1,3>,连红天3>,,COLORA20FFD,NODRAW;近期连红天:IF<连红天4=0,REF<连红天1,4>,连红天4>,COLORYELLOW,NODRAW;三日资金:SUM<资金收支,3>,COLORWHITE,NODRAW;五日资金:SUM<资金收支,5>,COLORFF00FF,NODRAW;十日资金:SUM<资金收支,10>,COLOR0000FF,NODRAW; 资金流量:=LLJX,LINETHICK0,COLOR0000FF; STICKLINE<<资金流量> 0>,动态天量+资金流量*20,动态天量,3,0>,COLOR0000FF;STICKLINE<<资金流量< 0>,动态天量+资金流量*20,动态天量,3,0>,COLOR008000;万手:VOL/10000,LINETHICK0;BB:=VOL/<<HIGH-LOW>*2-ABS<CLOSE-OPEN>>; TOTAL:=IF<PERIOD=1,5,IF<PERIOD=2,15,IF<PERIOD=3,30,IF<PERIOD=4,60,IF<PERIOD=5,TOTALFZNUM,1>>>>>; MTIME:=MOD<FROMOPEN,TOTAL>;CTIME:=IF<MTIME<0.5,TOTAL,MTIME>;VVOL:IF<CURRBARSCOUNT=1,VOL*TOTAL/CTIME,DR AWNULL>,NODRAW;STICKLINE<CURRBARSCOUNT=1,VVOL,0,-1,-1>,COLOR 00C0C0;VOLUME:VOL,VOLSTICK;MA VOL1:MA<VOLUME,M1>,COLOR80FFFF,LINETHICK1 ;MA VOL2:MA<VOLUME,M2>,COLORFF00FF,LINETHICK1 ;{变色彩带}V AR1:=<2*CLOSE+HIGH+LOW>/4;操盘线:<EMA<V AR1,2>+EMA<V AR1,3>+EMA<V AR1,5>+EMA<V AR1,8>+EMA<V AR1,11>+EMA<V AR1,13>>/6.4,COLORFFF F00,LINETHICK1,CIRCLEDOT;IF<操盘线>REF<操盘线,1>,操盘线,DRAWNULL>,COLOR0000FF,LINETHICK1,CIRCLEDO T;。
通达信指标公式源码 分类资金流向 副图源码
{********************************************超大单流向********************************************}超B:=L2_AMO(0,2)/10000.0;超S:=L2_AMO(0,3)/10000.0;超大单:(超B)-(超S),NODRAW,COLORRED;三日:SUM(超大单,3),COLORWHITE,NODRAW;五日:SUM(超大单,5),COLORYELLOW,NODRAW;十日:SUM(超大单,10),COLORMAGENTA,NODRAW; STICKLINE(超大单>0,0,超大单,2,0),COLORRED;STICKLINE(超大单<0,0,超大单,2,0),COLORCYAN;{********************************************大单流向********************************************}大B:=L2_AMO(1,2)/10000.0;大S:=L2_AMO(1,3)/10000.0;大单:(大B)-(大S),NODRAW,COLORMAGENTA;三日:SUM(大单,3),COLORWHITE,NODRAW;五日:SUM(大单,5),COLORYELLOW,NODRAW;十日:SUM(大单,10),COLORMAGENTA,NODRAW;STICKLINE(大单>0,2000,大单+2000,2,0),COLORMAGENTA; STICKLINE(大单<0,2000,大单+2000,2,0),COLORGREEN;{********************************************中单流向********************************************}中B:=L2_AMO(2,2)/10000.0;中S:=L2_AMO(2,3)/10000.0;中单:(中B)-(中S),NODRAW,COLORYELLOW;三日:SUM(中单,3),COLORWHITE,NODRAW;五日:SUM(中单,5),COLORYELLOW,NODRAW;十日:SUM(中单,10),COLORMAGENTA,NODRAW;STICKLINE(中单>0,0,中单,2,0),COLORYELLOW;STICKLINE(中单<0,0,中单,2,0),COLORLICYAN;{********************************************小单流向********************************************}小B:=L2_AMO(3,2)/10000.0;小S:=L2_AMO(3,3)/10000.0;小单:(小B)-(小S),NODRAW,COLORGREEN;三日:SUM(小单,3),COLORWHITE,NODRAW;五日:SUM(小单,5),COLORYELLOW,NODRAW;十日:SUM(小单,10),COLORMAGENTA,NODRAW;STICKLINE(小单>0,-2000,小单-2000,2,0),COLORBROWN; STICKLINE(小单<0,-2000,小单-2000,2,0),COLORBLUE;{********************************************BBD资金流向********************************************}超B:=L2_AMO(0,2)/10000.0;大B:=L2_AMO(1,2)/10000.0;中B:=L2_AMO(2,2)/10000.0;小B:=L2_AMO(3,2)/10000.0;超S:=L2_AMO(0,3)/10000.0;大S:=L2_AMO(1,3)/10000.0;中S:=L2_AMO(2,3)/10000.0;小S:=L2_AMO(3,3)/10000.0;资金流向:(超B+大B+中B+小B)-(超S+大S+中S+小S),NODRAW; STICKLINE(资金流向>0,0,资金流向,2,0),COLORRED; STICKLINE(资金流向<0,0,资金流向,2,0),COLORLIGREEN;三日流向:SUM(资金流向,5),NODRAW;五日流向:SUM(资金流向,5),NODRAW;十日流向:SUM(资金流向,10),NODRAW;。
通达信指标公式源码 分时攻击副图指标
昨收:=DYNAINFO(3);HH:=DYNAINFO(5);LL:=DYNAINFO(6);FK:=MAX(HH-昨收,昨收-LL)*0.1;ZS:=昨收-FK*3.2;Q1:=昨收-FK*3.22;Q2:=昨收-1*FK*3.22;Q3:=昨收-5*FK*3.2;TJ:=FILTER(C,239)>0,NODRAW;TJJ:=SUM(TJ,0),NODRAW;TJA:=CONST(TJJ),NODRAW;流通盘:CAPITAL*100/100000000,NODRAW;资金流入:=SUM(IF(C>REF(C,1),V,0),FROMOPEN),STICK,COLORRED;资金流出:=-SUM(IF(C<REF(C,1),V,0),FROMOPEN),STICK,COLOR00FF00; 资金出入:=资金流入+资金流出,COLORSTICK;NN:=2400;HD:=HHV(资金出入,NN);LD:=LLV(资金出入,NN);最高:=CONST(HD),NODRAW;最低:=CONST(LD),NODRAW;HLMAX:=最高;HLMIN:=最低;HLMN1:=(HLMAX+HLMIN)/2;HLMN2:=HLMAX-HLMIN;HLMN3:=(100-0)/2*1.3;HLMN4:=(100-0)/1*1.3;中间价轴:=(50-HLMN3)*HLMN2/HLMN4+HLMN1;轴差:=最高-最低;{好}DRAWBAND(资金出入,RGB(150,0,150),0,RGB(0,100,0));资金流量:资金出入,COLORFFFFFF,LINETHICK1;资金比:资金出入/SUM(V,FROMOPEN)*100,COLOR00FFFF,LINETHICK1;资金流量比:=IF(资金比>=0,(资金比+100)/2,100-ABS((资金比-100)/2));攻击量:=((HSL*0.50+REF(HSL,1)*0.33)+(REF(HSL,2)*0.17))*SUM(C,FROMOPEN)/FROMOPE N;攻击量A:=SUM(IF(C>REF(C,1),攻击量*V,0),FROMOPEN),COLOR0000FF,LINETHICK0;攻击量B:=-SUM(IF(C<REF(C,1),攻击量*V,0),FROMOPEN),COLOR00FF00,LINETHICK0; 攻击流量:攻击量A+攻击量B,COLORSTICK;NOTEXT攻击线:攻击流量,COLORYELLOW,LINETHICK1;攻击比:攻击流量/SUM(V,FROMOPEN)*100,COLORRED,LINETHICK1;资金攻击度:=IF(攻击比>=0,(攻击比+50),100-ABS((攻击比-50)));{STICKLINE(资金流量A>0,资金流量A,0,1,0),COLOR0000FF;STICKLINE(资金流量B<0,资金流量B,0,1,0),COLORFF0000;}DRAWRECTREL(110,10,400,90,RGB(0,75,200));DRAWRECTREL(110,10,250,90,RGB(0,250,50));DRAWRECTREL(110,10,100+CONST(资金流量比*300/100),90,RGB(200,50,0)); DRAWTEXT_FIX(1,0.000,0.00,0,STRCAT(STRCAT('【资金流量比】',CON2STR(资金流量比,2)),'%买')),COLORYELLOW;DRAWRECTREL(610,10,900,90,RGB(0,75,200));DRAWRECTREL(610,10,750,90,RGB(0,250,50));DRAWRECTREL(610,10,600+CONST(资金攻击度*300/100),90,RGB(175,50,0)); DRAWTEXT_FIX(1,0.500,0.00,0,STRCAT(STRCAT('【资金攻击度】',CON2STR(资金攻击度,2)),' %买')),COLORYELLOW;量:=VOL,VOLSTICK;五日量:=MA(量,5),COLORWHITE;TT:=BARSCOUNT(C);{取得有效收盘价}均价黄:=SUM(C*V,TT)/SUM(V,TT);{分时均线的取值}量两步:=MA(V,5)>REF(MA(V,5),1) AND REF(MA(V,5),1)>REF(MA(V,5),2);价两步:= C>=REF(C,1) AND REF(C,1)>REF(C,2);价上岗量破5:=C>均价黄AND V>MA(V,5);量起爆:=V>=REF(V,1)*1;价创新高:=C>=HHV(C,0);量创新高:=V>=HHV(V,0);对昨日涨幅:=(C/DYNAINFO(3)-1)*100<=1.50;{涨幅控制2个点以内}每日一点:=量两步AND 价两步AND 价上岗量破5 AND 量起爆AND 价创新高AND 量创新高AND 对昨日涨幅;{计算收益、已爆分钟}VV:=BARSSINCE(每日一点)+1;首次起爆价:=REF(C,VV-1),NODRAW;起爆收益:(DYNAINFO(7)-首次起爆价)/首次起爆价*100,NODRAW;起爆时间:=REF(TIME/10000,VV),NODRAW;已爆分钟:=VV-1,NODRAW;{画出底线和红球}首次起爆量:=REF(VOL,VV-1);DRAWICON(已爆分钟>=2,最低,8);{出现8,至少已经确认2分钟了};MMA30:=EMA(CLOSE,30);强弱界定:=IF(PERIOD=0 ,EMA(CLOSE,900),DRAWNULL);分时均价线:=SUM(C*V,240)/SUM(V,240),COLORYELLOW,LINETHICK2;BGTYU:=IF(DATE<=1150530,1,0);GHYJKU:=BETWEEN((DCLOSE*BGTYU)/(SUM(AMOUNT,BARSCOUNT((DCLOSE*BGTYU))) /SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))),1.05,0.95);VBNH:=IF(GHYJKU=0,MA((DCLOSE*BGTYU),BARSCOUNT((DCLOSE*BGTYU))),(SUM(AM OUNT,BARSCOUNT((DCLOSE*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))) );二十☆:=EXPMA((DCLOSE/VBNH),20),COLORRED,LINETHICK1;六十★:=EXPMA((DCLOSE/VBNH),60),COLORLIGREEN,LINETHICK1;FAA:=BARSLAST(TIME=100000);FCC:=REF(HHV(C,0),FAA+1);FVV:=REF(HHV(V,0),FAA+1);ZF:=FCC/DYNAINFO(3)<1.05;XG1:=CROSS(C,FCC) AND V>FVV AND ZF,COLORWHITE;FAA1:=BARSLAST(TIME=110000);FCC1:=REF(HHV(C,0),FAA1+1);FVV1:=REF(HHV(V,0),FAA1+1);ZF1:=FCC1/DYNAINFO(3)<1.05;XG2:=CROSS(C,FCC1) AND V>FVV1 AND ZF1,COLORYELLOW;突破:=XG1 OR XG2,COLORRED;VT:=BARSSINCE(突破)+1;首次突破价:=REF(C,VT-1),NODRAW;突破收益:(DYNAINFO(7)-首次突破价)/首次突破价*100,NODRAW;拉升量:=IF(C>REF(C,1),VOL,0);昨拉升最高值:=CONST(FINDHIGH(拉升量,FROMOPEN,240,1)),LINETHICK1,COLORMAGENTA;今拉升最高值:=CONST(REF(HHV(拉升量,FROMOPEN),0)),COLORYELLOW,NODRAW;攻击力度:=今拉升最高值/昨拉升最高值,NODRAW;STICKLINE(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,最低,1,0),COLORCYAN;STICKLINE(每日一点,最低+轴差*0.65,最低,1,0),COLORMAGENTA;STICKLINE(突破,最低+轴差*0.50,最低,1,0),COLORWHITE;STICKLINE(CROSS(EXPMA((DCLOSE/VBNH),60),EXPMA((DCLOSE/VBNH),120)),最低+轴差*0.35,最低,1,0),COLORYELLOW;STICKLINE(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低,最低+轴差*0.2,1,0),COLORGREEN; DRAWICON(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,1); DRAWICON(每日一点,最低+轴差*0.65,1);DRAWICON(突破,最低+轴差*0.50,17);DRAWICON(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低+轴差*0.2,9);DRAWTEXT(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,'☆攻击'),COLORCYAN;DRAWTEXT(每日一点,最低+轴差*0.65,'∠起爆'),COLORGREEN;DRAWNUMBER(每日一点,最低+轴差*0.55,首次起爆价),COLORGREEN; {DRAWTEXT(CURRBARSCOUNT=160,HHV(V,60)*0.9,'20线上行+日价K线突破+日K线量起爆更好+估换手小于10%时更稳定'),COLORGREEN;};DRAWTEXT(突破,最低+轴差*0.50,'分时突破'),COLORWHITE;DRAWNUMBER(突破,最低+轴差*0.40,首次突破价),COLORWHITE;DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),60),EXPMA((DCLOSE/VBNH),120)),最低+轴差*0.35,'★迹'),COLORYELLOW;{DRAWICON(CROSS(EXPMA((DCLOSE/VBNH),20),1.01),MAX(资金流量,攻击流量),18);} DRAWTEXT(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低+轴差*0.2,'关注'),COLORRED;。
看清主力资金副图源码通达信指标公式源码
ZLCM:=EMA(WINNER(CLOSE)*70,3);SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3); ZSHTL:=SHCM/(ZLCM+SHCM)*100;ZZLKP:=ZLCM/(ZLCM+SHCM)*100;ZCMZL:=MA(ZLCM+SHCM,13);ZZNTS:=BARSLAST(ZSHTL<90 AND REF(ZSHTL,1)>90);ZSHJJ:=EMA(ZSHTL,89);ZZLJJ:=EMA(ZZLKP,89);ZJLRQD:=INTPART(ZZLKP-ZZLJJ);SH8:=EMA(ZSHTL,8);DKB:=IF(ZZLKP-REF(ZZLKP,1)>ZSHTL-REF(ZSHTL,1),1,0);STICKLINE(REF(ZSHTL,1)>90 AND ZSHTL<90,ZSHTL,0,4,0),COLOR9966FF; STICKLINE(C>0,ZSHTL,ZZLKP,0,0),COLOREEEEEE;STICKLINE(ZSHJJ>REF(ZSHJJ,1),ZSHTL,ZSHJJ,1,0),COLORAAAAAA; STICKLINE(C>0,ZZLKP,0,3,0),COLORBLUE;STICKLINE(ZZLKP>75,ZZLKP,0,3,0),COLORFFFFFF;STICKLINE(ZZLJJ>REF(ZZLJJ,1),ZZLKP,ZZLJJ,3,0),COLORRED; STICKLINE(ZSHTL>=90,ZZLKP,0,3,0),COLORYELLOW;散户套牢系数:INTPART(ZSHTL),NODRAW;主力控盘系数:INTPART(ZZLKP),COLORCYAN,NODRAW;资金流入强度:ZJLRQD,NODRAW;RSV:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;K1:=SMA(RSV,10,1);D1:=SMA(K1,5,1);KK:=INTPART(K1);DD:=INTPART(D1);TFXXS:=KK+DD;TGLD:=MOD(TFXXS,10);TGLXS:=(TFXXS-REF(TFXXS,1))*10;TYCFX:=TFXXS+TGLXS;乖离系数:TGLXS,NODRAW,COLORGREEN;STICKLINE(TGLXS>0,150,150+TGLXS,3,0),COLOR000088;STICKLINE(TGLXS>0,150,150+TGLXS,2.5,0),COLOR000099;STICKLINE(TGLXS>0,150,150+TGLXS,2,0),COLOR0000AA;STICKLINE(TGLXS>0,150,150+TGLXS,1.5,0),COLOR0000BB;STICKLINE(TGLXS>0,150,150+TGLXS,1.0,0),COLOR0000DD;STICKLINE(TGLXS>0,150,150+TGLXS,0.5,0),COLOR0000FF;STICKLINE(TGLXS<0,150,150+TGLXS,3,0),COLOR008800;STICKLINE(TGLXS<0,150,150+TGLXS,2.5,0),COLOR00AA00;STICKLINE(TGLXS<0,150,150+TGLXS,2,0),COLOR00BB00;STICKLINE(TGLXS<0,150,150+TGLXS,1.5,0),COLOR00DD00;STICKLINE(TGLXS<0,150,150+TGLXS,1,0),COLOR00FF00;STICKLINE(TGLXS=0 AND REF(TGLXS,1)>=0,150,150+TGLXS,8,0),COLORRED; STICKLINE(TGLXS=0 AND REF(TGLXS,1)<0,150,150+TGLXS,8,0),COLORGREEN;风险系数:TFXXS,LINETHICK2,COLORYELLOW;预测风险:TYCFX,LINETHICK1,COLORCYAN;市场筹码总量:ZCMZL,COLORGREEN,LINETHICK1;上市:FINANCE(42)/10000,NODRAW,COLORYELLOW;STICKLINE(TGLXS>0 AND 100+TGLXS<TYCFX AND 100+REF(TGLXS,1)>=REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLOW; STICKLINE(TGLXS<0 AND 100+TGLXS>=TYCFX AND 100+REF(TGLXS,1)<REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0),COLORYELLOW;T1:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=1);T2:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=0);T3:=CONST( ZCMZL=REF(ZCMZL,1));T4:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=1);T5:=CONST( ZCMZL<REF(ZCMZL,1) AND DKB=0);T6:=CONST(TFXXS<=50 );T7:=CONST(TFXXS>=160 );T8:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS<=100 );T9:=CONST( TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS>100); T10:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) AND TFXXS>100 ); T11:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<REF(TFXXS,1) ANDTFXXS<=100 );T12:=CONST( ZSHTL>90 );T13:=CONST( ZZLKP>75 );T14:=CONST(CROSS(ZCMZL,ZZLJJ) AND ZZLKP>ZZLJJ AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T15:=CONST(CROSS(ZCMZL,ZZLKP) AND ZZLKP>ZZLJJ AND ZZLKP<ZSHTL AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T16:=CONST( CROSS(ZCMZL,ZSHTL) AND ZSHTL>ZZLKP AND ZCMZL>REF(ZCMZL,1)); T17:=CONST( CROSS(ZCMZL,100) AND ZCMZL>REF(ZCMZL,1));T18:=CONST(REF(ZSHTL,1)>90 AND ZSHTL<90 );TS1:=IF(T1=1,0+0.03,0);TS2:=IF(T2=1,TS1+0.03,TS1);TS3:=IF(T3=1,TS2+0.03,TS2);TS4:=IF(T4=1,TS3+0.03,TS3);TS5:=IF(T5=1,TS4+0.03,TS4);TS6:=IF(T6=1,0+0.73,0);TS7:=IF(T7=1,TS6+0.03,TS6);TS8:=IF(T8=1,TS7+0.03,TS7);TS9:=IF(T9=1,TS8+0.03,TS8);TS10:=IF(T10=1,TS9+0.03,TS9);TS11:=IF(T11=1,TS10+0.03,TS10);TS12:=IF(T12,0+0.03,0);TS13:=IF(T13=1,TS12+0.03,TS12);TS14:=IF(T14=1,TS13+0.03,TS13);TS15:=IF(T15=1,TS14+0.03,TS14);TS16:=IF(T16=1,TS15+0.03,TS15);TS17:=IF(T17=1,TS16+0.03,TS16);TS18:=IF(T8=1,TS17+0.03,TS17);DRAWTEXT_FIX(T1,0.58,TS1,0,'★主力动向监控:主力增仓'),COLORRED; DRAWTEXT_FIX(T2,0.58,TS2,0,'★主力动向监控:主力减仓'),COLORMAGENTA; DRAWTEXT_FIX(T3,0.58,TS3,0,'★主力动向监控:多空平衡'),COLORGRAY; DRAWTEXT_FIX(T4,0.58,TS4,0,'★主力动向监控:主力回补'),COLORFF9933; DRAWTEXT_FIX(T5,0.58,TS5,0,'★主力动向监控:主力出逃'),COLORGREEN; DRAWTEXT_FIX(T6,0.78,TS6,0,'★操作风险提示:买入风险'),COLORYELLOW; DRAWTEXT_FIX(T7,0.78,TS7,0,'★操作风险提示:卖出风险'),COLORCYAN; DRAWTEXT_FIX(T8,0.78,TS8,0,'★操作风险提示:追涨博弈'),COLORRED; DRAWTEXT_FIX(T9,0.78,TS9,0,'★操作风险提示:稳健持股'),COLORMAGENTA; DRAWTEXT_FIX(T10,0.76,TS10,0,'★操作风险提示:盘跌减仓'),COLORWHITE; DRAWTEXT_FIX(T11,0.76,TS11,0,'★操作风险提示:杀跌空仓'),COLORGREEN; DRAWTEXT_FIX(T12,0.36,TS12,0,'☆特别信号提示:筑底散兵坑'),COLOR66FFCC; DRAWTEXT_FIX(T13,0.36,TS13,0,'☆特别信号提示:铸顶风险区'),COLORCYAN; DRAWTEXT_FIX(T14,0.36,TS14,0,'☆特别信号提示:穿越主力'),COLORRED; DRAWTEXT_FIX(T15,0.36,TS15,0,'☆特别信号提示:穿越主力'),COLORYELLOW; DRAWTEXT_FIX(T16,0.36,TS16,0,'☆特别信号提示:穿越散户'),COLORGREEN;DRAWTEXT_FIX(T17,0.36,TS17,0,'☆特别信号提示:全盘穿越'),COLOR3399FF;。
通达信指标公式源码分时资金监控分时副图指标
超买:=IF((ISBUYORDER,AMOUNT>=(FINANCE(40)*0.05/100))AND(DCLOSE>=DOPEN),AM OUNT/10000,0);超卖:=IF((AMOUNT>=(FINANCE(40)*0.05/100))AND(DCLOSE<=DOPEN),AMOUNT/10000, 0);大买:=IF(((ISBUYORDER,AMOUNT>=(FINANCE(40)*0.025/100))AND(ISBUYORDER,AMOU NT<(FINANCE(40)*0.05/100)))AND(DCLOSE>=DOPEN),AMOUNT/10000,0);大卖:=IF(((AMOUNT>=(FINANCE(40)*0.025/100))AND(AMOUNT<(FINANCE(40)*0.05/100 )))AND(DCLOSE<=DOPEN),AMOUNT/10000,0);中买:=IF(((ISBUYORDER,AMOUNT>=(FINANCE(40)*0.005/100))AND(ISBUYORDER,AMOU NT<(FINANCE(40)*0.025/100)))AND(DCLOSE>=DOPEN),AMOUNT/10000,0);中卖:=IF(((AMOUNT>=(FINANCE(40)*0.005/100))AND(AMOUNT<(FINANCE(40)*0.025/10 0)))AND(DCLOSE<=DOPEN),AMOUNT/10000,0);散买:=IF((ISBUYORDER,AMOUNT<(FINANCE(40)*0.005/100))AND(DCLOSE>=DOPEN),AM OUNT/10000,0);散卖:=IF((AMOUNT<(FINANCE(40)*0.005/100))AND(DCLOSE<=DOPEN),AMOUNT/10000, 0);Z:=(SUM(超买,0)-SUM(超卖,0))+(SUM(大买,0)-SUM(大卖,0))+(SUM(中买,0)-SUM(中卖,0))+(SUM(散买,0)-SUM(散卖,0));★总净:Z,COLORSTICK;★主净:(SUM(超买,0)-SUM(超卖,0))+(SUM(大买,0)-SUM(大卖,0)),LINETHICK8,COLORYELLOW;★超净:SUM(超买,0)-SUM(超卖,0),COLORRED,LINETHICK2;★大净:SUM(大买,0)-SUM(大卖,0),COLORMAGENTA,LINETHICK2;★中净:SUM(中买,0)-SUM(中卖,0),COLORBLUE,LINETHICK1;★散净:SUM(散买,0)-SUM(散卖,0),COLORGREEN,LINETHICK1;DRAWTEXT(ISLASTBAR AND C,★主净,'★主力'),COLORYELLOW;DRAWTEXT(ISLASTBAR AND C,★超净,'★机构'),COLORRED;DRAWTEXT(ISLASTBAR AND C,★大净,'★大户'),COLORMAGENTA;DRAWTEXT(ISLASTBAR AND C,★中净,'★中户'),COLORBLUE;DRAWTEXT(ISLASTBAR AND C,★散净,'★散户'),COLORGREEN;。
通达信指标公式源码 主力筹码 副图源码
首先申明有未来函数WINNER,担心的慎用。
主力筹码:=IF(C<0,0,EMA(WINNER(CLOSE)*70,3));散户筹码:=IF(C<0,0,EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3));散户持仓:IF(C<0,0,散户筹码/(主力筹码+散户筹码)*100),COLORGREEN,NODRAW;主力持仓:IF(C<0,0,主力筹码/(主力筹码+散户筹码)*100),COLORRED,NODRAW;散户资金:=IF(C<0,0,EMA(散户持仓,89));主力资金:=IF(C<0,0,EMA(主力持仓,89));资金流入强度:IF(C<0,0,INTPART(主力持仓-主力资金)),NODRAW,COLOR0000FF;SH8:=IF(C<0,0,EMA(散户持仓,8));STICKLINE(CLOSE>0,散户持仓,主力持仓,1,0),COLORGRAY;STICKLINE(散户资金>REF(散户资金,1),散户持仓,散户资金,1,0),COLORWHITE; STICKLINE(CLOSE>0,主力持仓,0,1,0),COLORBROWN;STICKLINE(主力持仓>75,主力持仓,0,1,0),COLORRED;STICKLINE(主力资金>REF(主力资金,1),主力持仓,主力资金,1,0),COLORLIMAGENTA;STICKLINE(散户持仓>=90,主力持仓,0,1,0),COLORGREEN; STICKLINE(REF(散户持仓,1)>90 AND 散户持仓<90,0,散户持仓,1,0),COLORYELLOW;主力介入:REF(散户持仓,1)>90 AND 散户持仓<90,NODRAW;筹码总量:IF(C<0,0,MA(主力筹码+散户筹码,13)),NODRAW;筹码绿:IF(CLOSE>0,筹码总量,DRAWNULL),COLORGREEN,LINETHICK2; 筹码红:IF(筹码总量>REF(筹码总量,1),筹码总量,DRAWNULL),COLORRED,LINETHICK2;资金流入:IF(主力资金>REF(主力资金,1),主力持仓,DRAWNULL),COLORMAGENTA,NODRAW;DRAWTEXT(筹码总量>REF(筹码总量,1) AND SH8<REF(SH8,1) AND ISLASTBAR,筹码总量,'←增量资金');选股:COUNT(主力介入=1,3) AND 筹码红AND 资金流入,NODRAW,COLORYELLOW;。
通达信指标公式源码主力资金副图指标
通达信指标公式源码主力资金副图指标ZLCM:=EMA(WINNER(CLOSE)*70,3);SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3); ZSHTL:=SHCM/(ZLCM+SHCM)*100;ZZLKP:=ZLCM/(ZLCM+SHCM)*100;ZCMZL:=MA(ZLCM+SHCM,13);ZZNTS:=BARSLAST(ZSHTL<90 AND REF(ZSHTL,1)>90);ZSHJJ:=EMA(ZSHTL,89);ZZLJJ:=EMA(ZZLKP,89);ZJLRQD:=INTPART(ZZLKP-ZZLJJ);SH8:=EMA(ZSHTL,8);DKB:=IF(ZZLKP-REF(ZZLKP,1)>ZSHTL-REF(ZSHTL,1),1,0);STICKLINE(REF(ZSHTL,1)>90 AND ZSHTL<90,ZSHTL,0,4,0),COLOR9966FF;STICKLINE(C>0,ZSHTL,ZZLKP,0,0),COLOREEEEEE;STICKLINE(ZSHJJ>REF(ZSHJJ,1),ZSHTL,ZSHJJ,1,0),COLORAAA AAA; STICKLINE(C>0,ZZLKP,0,3,0),COLORBLUE;STICKLINE(ZZLKP>75,ZZLKP,0,3,0),COLORFFFFFF;STICKLINE(ZZLJJ>REF(ZZLJJ,1),ZZLKP,ZZLJJ,3,0),COLORRED; STICKLINE(ZSHTL>=90,ZZLKP,0,3,0),COLORYELLOW;散户套牢系数:INTPART(ZSHTL),NODRAW;主力控盘系数:INTPART(ZZLKP),COLORCYAN,NODRAW;资金流入强度:ZJLRQD,NODRAW;RSV:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;K1:=SMA(RSV,10,1);D1:=SMA(K1,5,1);KK:=INTPART(K1);DD:=INTPART(D1);TFXXS:=KK+DD;TGLD:=MOD(TFXXS,10);TGLXS:=(TFXXS-REF(TFXXS,1))*10;TYCFX:=TFXXS+TGLXS;乖离系数:TGLXS,NODRAW,COLORGREEN;STICKLINE(TGLXS>0,150,150+TGLXS,3,0),COLOR000088;STICKLINE(TGLXS>0,150,150+TGLXS,2.5,0),COLOR000099;STICKLINE(TGLXS>0,150,150+TGLXS,2,0),COLOR0000AA;STICKLINE(TGLXS>0,150,150+TGLXS,1.5,0),COLOR0000BB;STICKLINE(TGLXS>0,150,150+TGLXS,1.0,0),COLOR0000DD; STICKLINE(TGLXS>0,150,150+TGLXS,0.5,0),COLOR0000FF;STICKLINE(TGLXS<0,150,150+TGLXS,3,0),COLOR008800;STICKLINE(TGLXS<0,150,150+TGLXS,2.5,0),COLOR00AA00;STICKLINE(TGLXS<0,150,150+TGLXS,2,0),COLOR00BB00;STICKLINE(TGLXS<0,150,150+TGLXS,1.5,0),COLOR00DD00; STICKLINE(TGLXS<0,150,150+TGLXS,1,0),COLOR00FF00;STICKLINE(TGLXS=0 ANDREF(TGLXS,1)>=0,150,150+TGLXS,8,0),COLORRED;STICKLINE(TGLXS=0 ANDREF(TGLXS,1)<0,150,150+TGLXS,8,0),COLORGREEN;风险系数:TFXXS,LINETHICK2,COLORYELLOW;预测风险:TYCFX,LINETHICK1,COLORCYAN;市场筹码总量:ZCMZL,COLORGREEN,LINETHICK1;上市:FINANCE(42)/10000,NODRAW,COLORYELLOW;STICKLINE(TGLXS>0 AND 100+TGLXS<="" p="">100+REF(TGLXS,1)>=REF(TYCFX,1),0,(100+ABS(TGLXS)),0,0), COLORYELLO W;STICKLINE(TGLXS<0 AND 100+TGLXS>=TYCFX AND100+REF(TGLXS,1)<="" p="">T1:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=1);T2:=CONST( ZCMZL>REF(ZCMZL,1) AND DKB=0);T3:=CONST( ZCMZL=REF(ZCMZL,1));T4:=CONST( ZCMZLT5:=CONST( ZCMZLT6:=CONST(TFXXS<=50 );T7:=CONST(TFXXS>=160 );T8:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS<=100 );T9:=CONST( TFXXS>50 AND TFXXS<160 AND TFXXS>=REF(TFXXS,1) AND TFXXS>100);T10:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS100 );T11:=CONST(TFXXS>50 AND TFXXS<160 AND TFXXS<="" and="" p="" tfxxs<="100">T12:=CONST( ZSHTL>90 );T13:=CONST( ZZLKP>75 );T14:=CONST(CROSS(ZCMZL,ZZLJJ) AND ZZLKP>ZZLJJ AND ZZLKP>10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T15:=CONST(CROSS(ZCMZL,ZZLKP) AND ZZLKP>ZZLJJ AND ZZLKP10 AND ZZLJJ>REF(ZZLJJ,1) AND ZCMZL>REF(ZCMZL,1) );T16:=CONST( CROSS(ZCMZL,ZSHTL) AND ZSHTL>ZZLKP ANDZCMZL>REF(ZCMZL,1));T17:=CONST( CROSS(ZCMZL,100) ANDZCMZL>REF(ZCMZL,1));T18:=CONST(REF(ZSHTL,1)>90 AND ZSHTL<90 );TS1:=IF(T1=1,0+0.03,0);TS2:=IF(T2=1,TS1+0.03,TS1);TS3:=IF(T3=1,TS2+0.03,TS2);TS4:=IF(T4=1,TS3+0.03,TS3);TS5:=IF(T5=1,TS4+0.03,TS4);TS6:=IF(T6=1,0+0.73,0);TS7:=IF(T7=1,TS6+0.03,TS6);TS8:=IF(T8=1,TS7+0.03,TS7);TS9:=IF(T9=1,TS8+0.03,TS8);TS10:=IF(T10=1,TS9+0.03,TS9);TS11:=IF(T11=1,TS10+0.03,TS10);TS12:=IF(T12,0+0.03,0);TS13:=IF(T13=1,TS12+0.03,TS12);TS14:=IF(T14=1,TS13+0.03,TS13);TS15:=IF(T15=1,TS14+0.03,TS14);TS16:=IF(T16=1,TS15+0.03,TS15);TS17:=IF(T17=1,TS16+0.03,TS16);TS18:=IF(T8=1,TS17+0.03,TS17);DRAWTEXT_FIX(T1,0.58,TS1,0,'★主力动向监控:主力增仓'),COLORRED; DRAWTEXT_FIX(T2,0.58,TS2,0,'★主力动向监控:主力减仓'),COLORMAGENTA; DRAWTEXT_FIX(T3,0.58,TS3,0,'★主力动向监控:多空平衡'),COLORGRAY; DRAWTEXT_FIX(T4,0.58,TS4,0,'★主力动向监控:主力回补'),COLORFF9933; DRAWTEXT_FIX(T5,0.58,TS5,0,'★主力动向监控:主力出逃'),COLORGREEN; DRAWTEXT_FIX(T6,0.78,TS6,0,'★操作风险提示:买入风险'),COLORYELLOW; DRAWTEXT_FIX(T7,0.78,TS7,0,'★操作风险提示:卖出风险'),COLORCYAN; DRAWTEXT_FIX(T8,0.78,TS8,0,'★操作风险提示:追涨博弈'),COLORRED;DRAWTEXT_FIX(T9,0.78,TS9,0,'★操作风险提示:稳健持股'),COLORMAGENTA; DRAWTEXT_FIX(T10,0.76,TS10,0,'★操作风险提示:盘跌减仓'),COLORWHITE; DRAWTEXT_FIX(T11,0.76,TS11,0,'★操作风险提示:杀跌空仓'),COLORGREEN; DRAWTEXT_FIX(T12,0.36,TS12,0,'☆特别信号提示:筑底散兵坑'),COLOR66FFCC;DRAWTEXT_FIX(T13,0.36,TS13,0,'☆特别信号提示:铸顶风险区'),COLO RCYAN; DRAWTEXT_FIX(T14,0.36,TS14,0,'☆特别信号提示:穿越主力'),COLORRED; DRAWTEXT_FIX(T15,0.36,TS15,0,'☆特别信号提示:穿越主力'),COLORYELLOW;DRAWTEXT_FIX(T16,0.36,TS16,0,'☆特别信号提示:穿越散户'),COLORGREEN;DRAWTEXT_FIX(T17,0.36,TS17,0,'☆特别信号提示:全盘穿越'),COLOR3399FF;。
通达信副图资金柳(附源码)
通达信副图资金柳(附源码)总亿:AMOUNT/100000000,COLORFF00FF,NODRAW;VAR1:=AMOUNT/((HIGH-LOW)*2-ABS(CLOSE-OPEN));流入亿:IF(CLOSE>OPEN,VAR1*(HIGH-LOW),IF(CLOSE<OPEN,VAR1*((HIGH-OPEN)+(CLOSE-LOW)),AMOUNT/2))/100000000,COLORRED,NODRAW;流出亿:IF(CLOSE>OPEN,0-VAR1*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-VAR1*(HIGH-LOW),0-AMOUNT/2))/100000000,COLOR00FF00,NODRAW;额亿:流入亿+流出亿,COLORFFFF00,NODRAW;{线:=MA(CLOSE,1)-MA(CLOSE,6),NODRAW;}YUWEI:=MA(CLOSE,1)-MA(CLOSE,6),NODRAW;{量:(线),VOLSTICK;}分界:0;STICKLINE(YUWEI>0ANDYUWEI>REF(YUWEI,1),0,YUWEI,4,0)COLOR0D0C6A;STICKLINE(YUWEI>0ANDYUWEI>REF(YUWEI,1),0,YUWEI,3,0)COLOR0D06AA;STICKLINE(YUWEI>0ANDYUWEI>REF(YUWEI,1),0,YUWEI,1.5,0)COLOR2108C1;STICKLINE(YUWEI>0 AND YUWEI>REF(YUWEI,1),0,YUWEI,0.5,0)COLOR9F5DFF;STICKLINE(YUWEI>0ANDYUWEI<REF(YUWEI,1),0,YUWEI,4,0)COLOR22736F;STICKLINE(YUWEI>0ANDYUWEI<REF(YUWEI,1),0,YUWEI,3,0)COLOR22AAD5;STICKLINE(YUWEI>0ANDYUWEI<REF(YUWEI,1),0,YUWEI,1.5,0)COLOR10C7BF;STICKLINE(YUWEI>0ANDYUWEI<REF(YUWEI,1),0,YUWEI,0.5,0)COLOR80FFFF;STICKLINE(YUWEI<0ANDYUWEI<REF(YUWEI,1),0,YUWEI,4,0)COLOR1B7411;STICKLINE(YUWEI<0ANDYUWEI<REF(YUWEI,1),0,YUWEI,3,0)COLOR17A715;STICKLINE(YUWEI<0 AND YUWEI<REF(YUWEI,1),0,YUWEI,1.5,0)COLOR08D306;STICKLINE(YUWEI<0ANDYUWEI<REF(YUWEI,1),0,YUWEI,0.5,0)COLOR40FF00;STICKLINE(YUWEI<0ANDYUWEI>REF(YUWEI,1),0,YUWEI,4,0)COLOR080E71;STICKLINE(YUWEI<0ANDYUWEI>REF(YUWEI,1),0,YUWEI,3,0)COLOR0B0E8C;STICKLINE(YUWEI<0ANDYUWEI>REF(YUWEI,1),0,YUWEI,1.52,0)COLOR0905B0;STICKLINE(YUWEI<0ANDYUWEI>REF(YUWEI,1),0,YWEI,0.5,0)COLOR0204F2;DRAWTEXT(CROSS(0,YUWEI),0,'空');DRAWTEXT(CROSS(YUWEI,0),0,'买');。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
{********************************************超大单流向********************************************}
超B:=L2_AMO(0,2)/10000.0;
超S:=L2_AMO(0,3)/10000.0;
超大单:(超B)-(超S),NODRAW,COLORRED;
三日:SUM(超大单,3),COLORWHITE,NODRAW;
五日:SUM(超大单,5),COLORYELLOW,NODRAW;
十日:SUM(超大单,10),COLORMAGENTA,NODRAW; STICKLINE(超大单>0,0,超大单,2,0),COLORRED;
STICKLINE(超大单<0,0,超大单,2,0),COLORCYAN;
{********************************************大单流向********************************************}
大B:=L2_AMO(1,2)/10000.0;
大S:=L2_AMO(1,3)/10000.0;
大单:(大B)-(大S),NODRAW,COLORMAGENTA;
三日:SUM(大单,3),COLORWHITE,NODRAW;
五日:SUM(大单,5),COLORYELLOW,NODRAW;
十日:SUM(大单,10),COLORMAGENTA,NODRAW;
STICKLINE(大单>0,2000,大单+2000,2,0),COLORMAGENTA; STICKLINE(大单<0,2000,大单+2000,2,0),COLORGREEN;
{********************************************中单流向********************************************}
中B:=L2_AMO(2,2)/10000.0;
中S:=L2_AMO(2,3)/10000.0;
中单:(中B)-(中S),NODRAW,COLORYELLOW;
三日:SUM(中单,3),COLORWHITE,NODRAW;
五日:SUM(中单,5),COLORYELLOW,NODRAW;
十日:SUM(中单,10),COLORMAGENTA,NODRAW;
STICKLINE(中单>0,0,中单,2,0),COLORYELLOW;
STICKLINE(中单<0,0,中单,2,0),COLORLICYAN;
{********************************************小单流向
********************************************}
小B:=L2_AMO(3,2)/10000.0;
小S:=L2_AMO(3,3)/10000.0;
小单:(小B)-(小S),NODRAW,COLORGREEN;
三日:SUM(小单,3),COLORWHITE,NODRAW;
五日:SUM(小单,5),COLORYELLOW,NODRAW;
十日:SUM(小单,10),COLORMAGENTA,NODRAW;
STICKLINE(小单>0,-2000,小单-2000,2,0),COLORBROWN; STICKLINE(小单<0,-2000,小单-2000,2,0),COLORBLUE;
{********************************************BBD资金流向********************************************}
超B:=L2_AMO(0,2)/10000.0;
大B:=L2_AMO(1,2)/10000.0;
中B:=L2_AMO(2,2)/10000.0;
小B:=L2_AMO(3,2)/10000.0;
超S:=L2_AMO(0,3)/10000.0;
大S:=L2_AMO(1,3)/10000.0;
中S:=L2_AMO(2,3)/10000.0;
小S:=L2_AMO(3,3)/10000.0;
资金流向:(超B+大B+中B+小B)-(超S+大S+中S+小S),NODRAW; STICKLINE(资金流向>0,0,资金流向,2,0),COLORRED; STICKLINE(资金流向<0,0,资金流向,2,0),COLORLIGREEN;
三日流向:SUM(资金流向,5),NODRAW;
五日流向:SUM(资金流向,5),NODRAW;
十日流向:SUM(资金流向,10),NODRAW;。