通达信分时资金量能公式
昨收:=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;
C1:=CLOSE;
V1:=TIME;
A1:=COUNT(BARSCOUNT(C)=1 AND TIME<102000 ,0 );
T:=IF(V1<130000,(FLOOR(V1/10000)-9.5)*60+(FLOOR(V1/100)-100*FLOOR(V1/10000)),
(FLOOR(V1/10000)-11)*60+(FLOOR(V1/100)-100*FLOOR(V1/10000))),NODRAW;
TTA:=90;
KP30:=T<240;
KPGD:=H=HHV(H,0) AND KP30;
GDSJ:=BARSLAST(KPGD);
RCC:=DYNAINFO(3);
S2:=SMA(C,3,1);
S6:=SMA(C,5,1);
DK:=4*(S2-S6);
KK:=1;
{分时MACD}
DIF:=(EMA(CLOSE,13) - EMA(CLOSE,24));
DEA:=(EMA(DIF,6));
MACD:=3*(DIF-DEA);
LK:=STICKLINE(DK>0,RCC*KK,RCC*KK+DK,0,1),COLORRED;
UI:=STICKLINE(DK<0,RCC*KK,RCC*KK+DK,0,1),COLORCYAN;
RT:=STICKLINE(DK>0,RCC*KK,RCC*KK+DK,0,1),COLORRED;
{多头MACD}
DIFF:=EMA(CLOSE,240)-EMA(CLOSE,240)*100;
{股票指标网}
DEAA:=EMA(DIFF,18);
多头MACD:=(-3*(DIFF-DEAA))*20,NODRAW;
ZD:=HHV(多头MACD,0);
ZX:=LLV(多头MACD,0);
CZ:=(Q2-Q3)/6;
FDM:=MAX(ABS(ZD),ABS(ZX))*1.5;
RB:=(Q2+Q3)/2*0.99+2*(Q2-Q3)/4/FDM*多头MACD;
QQ:STICKLINE(多头MACD>0,RB,(Q2+Q3)/2*0.99,2.2,1),COLORRED,LINETHICK4;
GG:STICKLINE(多头MACD<0,RB,(Q2+Q3)/2*0.99,2,1),LINETHICK1,COLOR00AA00;
{强弱界定}
MMA30:=EMA(CLOSE,30)-(Q2+Q3)/2*0.01;
强弱界定:=EMA(CLOSE,900)-(Q2+Q3)/2*0.01;
AH:DRAWBAND(MMA30,RGB(200,100,0),强弱界定,RGB(0,150,150));
AD:=DRAWICON(CROSS(MMA30,强弱界定),H,1);
未来函数检测结果如下:
该公式包含未来函数:DYNAINFO
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
昨收赋值:DYNAINFO(3)
HH赋值:DYNAINFO(5)
LL赋值:DYNAINFO(6)
FK赋值:HH-昨收和昨收-LL较大值*0.1
ZS赋值:昨收-FK*3.2
Q1赋值:昨收-FK*3.22
Q2赋值:昨收-1*FK*3.22
Q3赋值:昨收-5*FK*3.2
TJ赋值:C的239过滤>0,NODRAW
TJJ:=0的TJ日累和,NODRAW
TJA:=CONST(TJJ),NODRAW
C1赋值:收盘价
V1赋值:TIME
A1赋值:COUNT(C的有效数据周期数=1 AND TIME<102000 ,0 )
T赋值:IF(V1<130000,(FLOOR(V1/10000)-9.5)*60+(FLOOR(V1/100)-100*FLOOR(V1/10000)),
(FLOOR(V1/10000)-11)*60+(FLOOR(V1/100)-100*FLOOR(V1/10000))),NODRAW
TTA:=90
KP30赋值:T<240
KPGD赋值:H=0日内H最高值 AND KP30
GDSJ赋值:上次KPGD距今天数
RCC赋值:DYNAINFO(3)
C的3日[1日权重]移动平均
C的5日[1日权重]移动平均
DK赋值:4*(S2-S6)
KK赋值:1
{分时MACD}
DIF赋值:(收盘价的13日指数移动平均 - 收盘价的24日指数移动平均)
DEA赋值:(DIF的6日指数移动平均)
MACD赋值:3*(DIF-DEA)
当满足条件DK>0时,在RCC*KK和RCC*KK+DK之间画柱状线
当满足条件DK<0时,在RCC*KK和RCC*KK+DK之间画柱状线
当满足条件DK>0时,在RCC*KK和RCC*KK+DK之间画柱状线
{多头MACD}
DIFF赋值:收盘价的240日指数移动平均-收盘价的240日指数移动平均*100
{股票指标网}
DEAA:=DIFF的18日指数移动平均
多头MACD赋值:(-3*(DIFF-DEAA))*20,NODRAW
ZD赋值:0日内多头MACD最高值
ZX赋值:0日内多头MACD最低值
CZ赋值:(Q2-Q3)/6
FDM赋值:MAX(ZD的绝对值,ABS(ZX))*1.5
RB赋值:(Q2+Q3)/2*0.99+2*(Q2-Q3)/4/FDM*多头MACD
输出
QQ:STICKLINE(多头MACD>0,RB,(Q2+Q3)/2*0.99,2.2,1),画红色,LINETHICK4
输出
GG:STICKLINE(多头MACD<0,RB,(Q2+Q3)/2*0.99,2,1),LINETHICK1,COLOR00AA00
{强弱界定}
MMA30赋值:收盘价的30日指数移动平均-(Q2+Q3)/2*0.01
强弱界定赋值:收盘价的900日指数移动平均-(Q2+Q3)/2*0.01
输出
AH:DRAWBAND(MMA30,RGB(200,100,0),强弱界定,RGB(0,150,150))
AD赋值:DRAWICON(MMA30上穿强弱界定,H,1)