通达信指标公式源码资金主图-源码
MA5:EXPMA(CLOSE,5) LINETHICK2;
MA10:EXPMA(CLOSE,14) LINETHICK2;
MA20:=EXPMA(CLOSE,20)NODRAW;
MA60:=EXPMA(CLOSE,60);
MA90:=EXPMA(CLOSE,90)NODRAW;
角度:=ATAN((MA5/REF(MA5,1)-1)*100)*180/3.1416,COLORMAGENTA,NODRAW;
IF(角度>=-10,MA5,DRAWNULL),COLORRED LINETHICK2;
STICKLINE(CROSS(MA5,MA10),L,L-0.05,2,0),COLORWHITE;
DRAWTEXT(CROSS(MA5,MA10),L-0.13,'牛') ,COLORWHITE;
STICKLINE(CROSS(MA5,MA20),L,L-0.05,2,0),COLOR00FFFF;
DRAWTEXT(CROSS(MA5,MA20),L-0.13,'大牛') ,COLOR00FFFF;
STICKLINE(CROSS(MA10,MA5),H,H+0.05,2,0),COLORBLUE;
DRAWTEXT(CROSS(MA10,MA5),H+0.13,'走人') ,COLORGREEN;
超B:=L2_AMO(0,0)/10000.0;
大B:=L2_AMO(1,0)/10000.0;
中B:=L2_AMO(2,0)/10000.0;
:=L2_AMO(3,0)/10000.0;
超S:=-L2_AMO(0,1)/10000.0;
大S:=-L2_AMO(1,1)/10000.0;
中S:=-L2_AMO(2,1)/10000.0;
小S:=-L2_AMO(3,1)/10000.0;
中单:=(中B)+(中S);
小单:=(小B)+(小S);
主力净流入:"Z02.主力净流入#DAY" LINETHICK2,COLORYELLOW CIRCLEDOT NODRAW;
超大单:"Z02.超大单#DAY" LINETHICK2,COLORYELLOW CIRCLEDOT NODRAW;
大单:"Z02.大单#DAY" LINETHICK2,COLORYELLOW CIRCLEDOT NODRAW;
V5:=SUM(主力净流入,5) NODRAW;
V10:=SUM(主力净流入,10) NODRAW;
阳:=IF(主力净流入>0 ,CLOSE>OPEN,0)NODRAW;
阴:=IF(主力净流入<0 ,CLOSE<OPEN,0)NODRAW;
STICKLINE(阳,CLOSE,OPEN,2,0) ,COLORRED;
STICKLINE(阴,C,O,2,0),COLORGREEN;
阳1:=IF(主力净流入<0 ,CLOSE>OPEN,0)NODRAW;
阴1:=IF(主力净流入>0,CLOSE<OPEN,0)NODRAW;
STICKLINE(阳1,CLOSE,OPEN,1.5,0) ,COLORYELLOW ;
芙蓉出水STICKLINE(阴1,C,O,1.5,0),COLORFF00FF;
V20:=SUM(主力净流入,20) NODRAW;
STICKLINE((CROSS(主力净流入,V5) AND 主力净流入>0),L,L-0.09,3,0),COLORD9D919;
DRAWTEXT((CROSS(主力净流入,V5) AND 主力净流入>0),L-0.13,'突破') ,COLORD9D919;
资金异动:=主力净流入>0 AND (主力净流入/CAPITAL)*100>=0.05,COLORYELLOW,NODRAW;
DRAWTEXT(C>REF(C,1) AND 资金异动 ,L-0.15,'异动'),COLORYELLOW;
主买A:="Z02.主买A#DAY" LINETHICK2,COLORYELLOW CIRCLEDOT NODRAW;
主卖A:="Z02.主卖A#DAY" LINETHICK2,COLORYELLOW CIRCLEDOT 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,NODRAW;
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);
D01:=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;
{VOL5:=MA(净量,5),COLORWHITE;
VOL10:=MA(净量,10),COLORYELLOW;
VOL40:=MA(净量,40),COLORFF00FF ;
量托:=VOL5>=VOL40 AND CROSS(VOL10,VOL40) AND REF(VOL10,1)<REF(VOL40,1);
DRAWTEXT(量托,L-0.012,'量托'),COLORWHITE;}
AA1:=BARSLAST(MA60>MA20 AND (MA20=MA10 OR MA20>MA10));
BB1:=REF(COUNT(C<MA60,AA1)=AA1,1);
CC1:=CROSS(C,MA60) AND VOL>MA(VOL,5) AND (C-REF(C,1))/REF(C,1)*100>3;

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。