通达信分时跟庄
DRAWGBK(C>0, RGB(0,10,10),RGB(48,0,0),0,'11',0);
A1:=(DVOL/C)/2,NODRAW;
A2:=SUM(IF(A1>100 AND CLOSE>REF(CLOSE,1),A1,0),0);
A3:=SUM(IF(A1>100 AND CLOSE<REF(CLOSE,1),A1,0),0);
A4:=SUM(IF(A1<100 AND CLOSE>REF(CLOSE,1),A1,0),0);
A5:=SUM(IF(A1<100 AND CLOSE<REF(CLOSE,1),A1,0),0);
A6:=A2+A3+A4+A5;
主买:(A2/A6)*100,LINETHICK1,COLORRED;
主卖:(A3/A6)*100,LINETHICK1,COLORCYAN;
散买:(A4/A6)*100,LINETHICK0;
散卖:(A5/A6)*100,LINETHICK0;
主差:主买-主卖,LINETHICK1,NODRAW;
散差:散买-散卖,LINETHICK0,NODRAW;
DRAWTEXT(主差>0 AND REF(主差,1)<=0,C*2,'抢'),COLOR5B91FF;
DRAWTEXT(主差<0 AND REF(主差,1)>=0,C*1,'主'),COLORWHITE;
DRAWTEXT(散差>0 AND REF(散差,1)<=0,C*2,'散'),COLORCYAN;
DRAWTEXT(散差<0 AND REF(散差,1)>=0,C*1,'入'),COLOR5B91FF;
VAR1:=((CLOSE - LLV(LOW,50))/(HHV(HIGH,50) - LLV(LOW,50)))*(100);
VAR2:=REVERSE(VAR1);
VAR3:=SMA(VAR1,6,1);
K:=SMA(VAR3,4,1);
D:=SMA(K,4,1);
DRAWTEXT(CROSS(K,D) AND MA(CLOSE,5)<CLOSE,D,'★'),COLOR5B91FF;
DRAWTEXT(CROSS(D,K) AND MA(CLOSE,5),D,'★'),COLORCYAN;
STICKLINE((K >= D),K,D,6,0),COLOR0000A8;
STICKLINE((K >= D),K,D,5,0),COLOR0000C0;
STICKLINE((K >= D),K,D,4,0),COLOR0000E0;
STICKLINE((K >= D),K,D,3,0),COLOR0000F0;
STICKLINE((K >= D),K,D,2,0),COLOR0000D0;
STICKLINE((K >= D),K,D,1,0),COLOR8080FF;
STICKLINE((K <= D),K,D,6,0),COLOR008800;
STICKLINE((K <= D),K,D,5,0),COLOR009900;
STICKLINE((K <= D),K,D,4,0),COLOR00AA00;
STICKLINE((K <= D),K,D,3,0),COLOR00BB00;
STICKLINE((K <= D),K,D,2,0),COLOR00CC00;
STICKLINE((K <= D),K,D,1,0),COLOR00DD00;
顶:90,DOTLINE;
底:10,DOTLINE,COLOR808080;
未来函数检测结果如下:
该公式包含未来函数:DVOL
解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
DRAWGBK(C>0, RGB(0,10,10),RGB(48,0,0),0,'11',0)
A1赋值:(D成交量/C)/2,NODRAW
A2赋值:SUM(IF(A1>100 AND 收盘价>1日前的收盘价,A1,0),0)
A3赋值:SUM(IF(A1>100 AND 收盘价<1日前的收盘价,A1,0),0)
A4赋值:SUM(IF(A1<100 AND 收盘价>1日前的收盘价,A1,0),0)
A5赋值:SUM(IF(A1<100 AND 收盘价<1日前的收盘价,A1,0),0)
A6赋值:A2+A3+A4+A5
输出主买:(A2/A6)*100,LINETHICK1,COLORRED
输出主卖:(A3/A6)*100,LINETHICK1,画青色
输出散买:(A4/A6)*100,LINETHICK0
输出散卖:(A5/A6)*100,LINETHICK0
输出主差:主买-主卖,LINETHICK1,NODRAW
输出散差:散买-散卖,LINETHICK0,NODRAW
DRAWTEXT(主差>0 AND 1日前的主差<=0,C*2,'抢'),COLOR5B91FF
DRAWTEXT(主差<0 AND 1日前的主差>=0,C*1,'主'),画白色
DRAWTEXT(散差>0 AND 1日前的散差<=0,C*2,'散'),画青色
DRAWTEXT(散差<0 AND 1日前的散差>=0,C*1,'入'),COLOR5B91FF
VAR1赋值:((收盘价 - 50日内最低价最低值)/(50日内最高价最高值 - 50日内最低价最低值))*(100)
VAR2赋值:VAR1的相反数
VAR1的6日[1日权重]移动平均
VAR3的4日[1日权重]移动平均
K的4日[1日权重]移动平均
DRAWTEXT(K上穿D AND 收盘价的5日简单移动平均<收盘价,D,'★'),COLOR5B91FF
DRAWTEXT(D上穿K AND 收盘价的5日简单移动平均,D,'★'),画青色
STICKLINE((K >= D),K,D,6,0),COLOR0000A8
STICKLINE((K >= D),K,D,5,0),COLOR0000C0
STICKLINE((K >= D),K,D,4,0),COLOR0000E0
STICKLINE((K >= D),K,D,3,0),COLOR0000F0
STICKLINE((K >= D),K,D,2,0),COLOR0000D0
STICKLINE((K >= D),K,D,1,0),COLOR8080FF
STICKLINE((K <= D),K,D,6,0),COLOR008800
STICKLINE((K <= D),K,D,5,0),COLOR009900
STICKLINE((K <= D),K,D,4,0),COLOR00AA00
STICKLINE((K <= D),K,D,3,0),COLOR00BB00
STICKLINE((K <= D),K,D,2,0),COLOR00CC00
STICKLINE((K <= D),K,D,1,0),COLOR00DD00
输出顶:90,DOTLINE
输出底:10,DOTLINE,COLOR808080