载入中...
在线检测未来函数
载入中...

通达信春牛图主图指标公式

来源:Internet,编辑:股旁网,2019-07-04

N:=20;
M:=32;
P1:=80;
P2:=100;
Q1:=5;
Q2:=10;
Q3:=20;
Q4:=30;
{九转}
A1:=C>REF(C,4);
A2:=BARSLASTCOUNT(A1);
A3:=REF(A2,1)=8 AND A2>REF(A2,1);
A4:=REF(BETWEEN(A2,5,8),1) AND A2<REF(A2,1);
A5:=ISLASTBAR AND BETWEEN(A2,6,8);
A6:=(BACKSET(A3>0,9) OR BACKSET(A4>0,A2+1)*0 OR BACKSET(A5>0,A2))*A2;
DRAWTEXT(A6>0,H+H*0.02,VAR2STR(A6,0)),COLORFF00FF;
DRAWTEXT(A2=9,H+H*0.02,'9'),COLOR00FF00;
B1:=C<REF(C,4);
B2:=BARSLASTCOUNT(B1);
B3:=REF(B2,1)=8 AND B2>REF(B2,1);
B4:=REF(BETWEEN(B2,5,8),1) AND B2<REF(B2,1);
B5:=ISLASTBAR AND BETWEEN(B2,6,8);
B6:=(BACKSET(B3>0,9) OR BACKSET(B4>0,B2+1)*0 OR BACKSET(B5>0,B2))*B2;
DRAWTEXT(B6>0,L-L*0.02,VAR2STR(B6,0)),COLOR00FF00;
DRAWTEXT(B2=9,L-L*0.02,'9'),COLORFF00FF;
{左上角文字}
DRAWTEXT_FIX(1,0.02,0.115,0,'所属行业地域概念:'),COLORYELLOW;
DRAWTEXT_FIX(1,0.13,0.115,0,HYBLOCK),COLOR0000FF;{所属行业}
DRAWTEXT_FIX(1,0.18,0.115,0,DYBLOCK),COLORFF00FF;{所属地域}
DRAWTEXT_FIX(1,0.23,0.115,0,GNBLOCK),COLOR0088FF;{所属概念}
DRAWTEXT_FIX(1,0.02,0.17,0,'所属风格板块:'),COLOR00FFAA;
DRAWTEXT_FIX(1,0.10,0.17,0,FGBLOCK),COLOR00FFFF;{所属风格板块};
{控盘系数}
ZLCM:=EMA(WINNER(CLOSE)*70,3);{//主力筹码估算}
SHCM:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,3);{//散户筹码估算}
ZZLKP:=ZLCM/(ZLCM+SHCM)*100;{//主力控盘筹码比率}
控盘系数%:=INTPART(ZZLKP),NODRAW;
高度控盘:=CROSS(控盘系数%,50);
DRAWTEXT_FIX(1,0.02,0.23,0,STRCAT('控盘系数%:',CON2STR(控盘系数%,2))),COLORYELLOW;
{筹码峰}
DRAWTEXT_FIX(1,0.07,0.23,0,EXTERNSTR(0,2))COLORFF00FF;
DRAWTEXT_FIX(1,0.15,0.23,0,'筹码峰:')COLORWHITE;
DRAWNUMBER_FIX(1,0.21,0.23,0,WINNER(C)*100)COLORWHITE;
{金牛趋势线}
VAR1:=(C+H+O+L)/4;
WUJIA:=(3*CLOSE+OPEN+LOW+HIGH)/6;
金牛:(20*WUJIA+19*REF(WUJIA,1)+18*REF(WUJIA,2)+17*REF(WUJIA,3)+16*REF(WUJIA,4)+15*REF(WUJIA,5)+14*REF(WUJIA,6)
+13*REF(WUJIA,7)+12*REF(WUJIA,8)+11*REF(WUJIA,9)+10*REF(WUJIA,10)+9*REF(WUJIA,11)+8*REF(WUJIA,12)
+7*REF(WUJIA,13)+6*REF(WUJIA,14)+5*REF(WUJIA,15)+4*REF(WUJIA,16)+3*REF(WUJIA,17)+2*REF(WUJIA,18)+
REF(WUJIA,20))/210,COLORYELLOW, LINETHICK2;
LIXIN:=EMA(金牛,2);
IF( 金牛>LIXIN,金牛,DRAWNULL), COLORRED, LINETHICK2;
{五日线}
MA5:MA(CLOSE,Q1);
MA10:MA(CLOSE,Q2),NODRAW;
MA20:MA(CLOSE,Q3),NODRAW;
MA60:MA(CLOSE,Q4),COLORWHITE,NODRAW;
Y1:=(C+L+H)/3;
Y2:=EMA(Y1,6);
Y3:=EMA(Y2,5);
DRAWICON(CROSS(Y2,Y3),L*0.98,7),NODRAW;
XG:CROSS(Y2,Y3),NODRAW;
DRAWICON(CROSS(Y3,Y2),H*1.02,8),NODRAW;
{买入提示}
MAA5:MA(C,5),COLORFF00FF,LINETHICK0;
MAA10:=MA(C,10);
MAA30:MA(C,30),COLORRED,LINETHICK0;
KS:IF(MAA10>MAA30,MAA10,MAA30),COLORBLUE,LINETHICK0;
AA3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
AA4:=SMA(AA3,3,1);
AA5:=SMA(AA4,3,1);
AA6:=3*AA4-2*AA5;
AA7:=C-REF(C,1);
AA8:=100*EMA(EMA(AA7,6),6)/EMA(EMA(ABS(AA7),6),6);
买:=LLV(AA8,2)=LLV(AA8,7) AND COUNT(AA8<0,2) AND CROSS(AA8,MA(AA8,2));
DRAWTEXT(FILTER(买=1,5),LOW-0.05,'↖买'),COLORYELLOW;
STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;

通达信春牛图主图指标公式

 

相关文章