返回列表

请高手看看这个通达信分时资金主图公式错在哪里?

[通达信]
2531977 Lv.2

专栏

查看:8213 评论:3 复制 设置 显示全部楼层 倒序浏览 |
跳转到指定楼层
设置
请高手看看下面这个通达信分时资金主图公式错在哪里,这个公式是我在网上下载请别人帮忙特别版的通达信tni格式公式,请高人帮忙修改一下,如果修改之后做出如图一样的效果感谢不尽,也是为广大股民朋友服务,在此等候高手们的答疑解惑!先谢谢了!
通达信分时资金主图源码:
M0:=ZST1.VOL0#DAY;
M1:=ZST1.VOL1#DAY;
M2:=ZST1.VOL2#DAY;
M3:=ZST1.VOL3#DAY;
M4:=ZST1.VOL4#DAY;
M5:=ZST1.VOL5#DAY;
M6:=ZST1.VOL6#DAY;
M7:=ZST1.VOL7#DAY;
M8:=ZST1.VOL8#DAY;
M9:=ZST1.VOL9#DAY;
MAXV:=ZST1.MAXV#DAY;
R0:=ZST1.R0#DAY;
R1:=ZST1.R1#DAY;
R2:=ZST1.R2#DAY;
R3:=ZST1.R3#DAY;
R4:=ZST1.R4#DAY;
R5:=ZST1.R5#DAY;
R6:=ZST1.R6#DAY;
R7:=ZST1.R7#DAY;
R8:=ZST1.R8#DAY;
R9:=ZST1.R9#DAY;
RR0:=ZST1.RR0#DAY;
RR1:=ZST1.RR1#DAY;
RR2:=ZST1.RR2#DAY;
RR3:=ZST1.RR3#DAY;
RR4:=ZST1.RR4#DAY;
RR5:=ZST1.RR5#DAY;
RR6:=ZST1.RR6#DAY;
RR7:=ZST1.RR7#DAY;
RR8:=ZST1.RR8#DAY;
RR9:=ZST1.RR9#DAY;
DRAWRECTREL(990,CONST(1000-(M0*500/MAXV)),1000,1000,IF(IF(RR0=1,RR0,R0),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(975,CONST(1000-(M1*500/MAXV)),985,1000,IF(IF(RR1=1,RR1,R1),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(960,CONST(1000-(M2*500/MAXV)),970,1000,IF(IF(RR2=1,RR2,R2),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(945,CONST(1000-(M3*500/MAXV)),955,1000,IF(IF(RR3=1,RR3,R3),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(930,CONST(1000-(M4*500/MAXV)),940,1000,IF(IF(RR4=1,RR4,R4),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(915,CONST(1000-(M5*500/MAXV)),925,1000,IF(IF(RR5=1,RR5,R5),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(900,CONST(1000-(M6*500/MAXV)),910,1000,IF(IF(RR6=1,RR6,R6),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(885,CONST(1000-(M7*500/MAXV)),895,1000,IF(IF(RR7=1,RR7,R7),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(870,CONST(1000-(M8*500/MAXV)),880,1000,IF(IF(RR8=1,RR8,R8),RGB(255,0,0),RGB(23,125,225)));
DRAWRECTREL(855,CONST(1000-(M9*500/MAXV)),865,1000,IF(IF(RR9=1,RR9,R9),RGB(255,0,0),RGB(23,125,225)));
QM0:=ZST1.净流入#DAY;
QM1:=ZST1.超大单#DAY;
QM2:=ZST1.大单#DAY;
QM3:=ZST1.中单#DAY;
QM4:=ZST1.小单#DAY;
QMAXV:=ZST1.DAZHI#DAY;
{DRAWRECTREL(0,649,252,999.2,IF(120,RGB(10,0,0),0));}
DRAWRECTREL(0,CONST(950-(ABS(QM0)*200/QMAXV)),40,950,IF(CONST(QM0)>0,RGB(100,0,0),RGB(0,50,0)));
DRAWRECTREL(50,CONST(950-(ABS(QM1)*200/QMAXV)),90,950,IF(CONST(QM1)>0,RGB(100,0,0),RGB(0,50,0)));
DRAWRECTREL(100,CONST(950-(ABS(QM2)*200/QMAXV)),140,950,IF(CONST(QM2)>0,RGB(100,0,0),RGB(0,50,0)));
DRAWRECTREL(150,CONST(950-(ABS(QM3)*200/QMAXV)),190,950,IF(CONST(QM3)>0,RGB(100,0,0),RGB(0,50,0)));
DRAWRECTREL(200,CONST(950-(ABS(QM4)*200/QMAXV)),240,950,IF(CONST(QM4)>0,RGB(100,0,0),RGB(0,50,0)));
DRAWTEXT_FIX(CURRBARSCOUNT=1,0,1,0,'净流'),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.053,1,0,'超大'),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.103,1,0,'大户'),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.153,1,0,'中户'),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.204,1,0,'散户'),COLORYELLOW;
MD:=EMA(C,1)-EMA(C,5);
STICKLINE(MD>0,DYNAINFO(3),DYNAINFO(3)+MD*2,0,1),COLOR5151A2;
STICKLINE(MD<=0,DYNAINFO(3),DYNAINFO(3)+MD*2,0,1),COLOR74743A;
分时线:CLOSE,COLORWHITE;
MM:=0.805;
MM1:=0.105;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.003,MM-ABS(QM0)*MM1/QMAXV,0,CEILING(QM0)),COLORRED;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.053,MM-ABS(QM1)*MM1/QMAXV,0,CEILING(QM1));
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.103,MM-ABS(QM2)*MM1/QMAXV,0,CEILING(QM2)),COLORLIBLUE;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.153,MM-ABS(QM3)*MM1/QMAXV,0,CEILING(QM3));
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.204,MM-ABS(QM4)*MM1/QMAXV,0,CEILING(QM4));
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.253,1,0,'单位(万元)'),COLORYELLOW;
分时均价线:SUM(C*V,240)/SUM(V,240),COLORYELLOW,LINETHICK1.5;


通达信分时资金主图引用的公式:
VOL0:VOL;
VOL1:REF(VOL,1);
VOL2:REF(VOL,2);
VOL3:REF(VOL,3);
VOL4:REF(VOL,4);
VOL5:REF(VOL,5);
VOL6:REF(VOL,6);
VOL7:REF(VOL,7);
VOL8:REF(VOL,8);
VOL9:REF(VOL,9);
MAXV:HHV(VOL,10);
R0:CLOSE>OPEN;
RR0:IF(C=O AND C>=REF(C,1),1,0);
R1:REF(CLOSE,1)>REF(OPEN,1);
RR1:IF(REF(C,1)=REF(O,1) AND REF(C,1)>=REF(C,2),1,0);
R2:REF(CLOSE,2)>REF(OPEN,2);
RR2:IF(REF(C,2)=REF(O,2) AND REF(C,2)>=REF(C,3),1,0);
R3:REF(CLOSE,3)>REF(OPEN,3);
RR3:IF(REF(C,3)=REF(O,3) AND REF(C,3)>=REF(C,4),1,0);
R4:REF(CLOSE,4)>REF(OPEN,4);
RR4:IF(REF(C,4)=REF(O,4) AND REF(C,4)>=REF(C,5),1,0);
R5:REF(CLOSE,5)>REF(OPEN,5);
RR5:IF(REF(C,5)=REF(O,5) AND REF(C,5)>=REF(C,6),1,0);
R6:REF(CLOSE,6)>REF(OPEN,6);
RR6:IF(REF(C,6)=REF(O,6) AND REF(C,6)>=REF(C,7),1,0);
R7:REF(CLOSE,7)>REF(OPEN,7);
RR7:IF(REF(C,7)=REF(O,7) AND REF(C,7)>=REF(C,8),1,0);
R8:REF(CLOSE,8)>REF(OPEN,8);
RR8:IF(REF(C,8)=REF(O,8) AND REF(C,8)>=REF(C,9),1,0);
R9:REF(CLOSE,9)>REF(OPEN,9);
RR9:IF(REF(C,9)=REF(O,9) AND REF(C,9)>=REF(C,10),1,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;
净流入:(超B+大B+中B+小B)-(超S+大S+中S+小S),NODRAW;
超大单:(超B)-(超S),NODRAW;
大单:(大B)-(大S),NODRAW;
中单:(中B)-(中S),NODRAW;
小单:(小B)-(小S),NODRAW;
DAZHI:CONST(MAX(ABS(净流入),MAX(ABS(超大单),MAX(ABS(大单),MAX(ABS(中单),ABS(小单)))))),NODRAW;

附件

原公式效果图

原公式效果图
977.middle
2531977 Lv.2

专栏

发表于:2012-7-10 19:35 复制 查看全部楼层 屏蔽
游客,您是(游客)级别,无法查看回复内容,请到新手区学习升级之后才能查看,或直接购买升级后查看。
557.middle
2095557 Lv.7

专栏

发表于:2012-7-10 20:00 复制 查看全部楼层 屏蔽
游客,您是(游客)级别,无法查看回复内容,请到新手区学习升级之后才能查看,或直接购买升级后查看。
977.middle
2531977 Lv.2

专栏

发表于:2012-7-10 22:02 复制 查看全部楼层 屏蔽
游客,您是(游客)级别,无法查看回复内容,请到新手区学习升级之后才能查看,或直接购买升级后查看。
您需要登录后才可以回帖 登录

本版积分规则 《理想财富服务协议》《免责声明》

楼主
2楼
3楼
4楼
广告
广告
站长推荐 /2

最新主题