以下是通达信短线进出副图源码(无源码的请下载附件导入)
{资金}
V0:=IF(C=O=H=L,0,(C-O)/(H-L)*VOL*CLOSE*100/10000);
V1:=IF(C>REF(C,1) AND C=O=H=L,VOL*CLOSE*100/10000,0);
V2:=IF(C<REF(C,1) AND C=O=H=L,-VOL*CLOSE*100/10000,0);
V3:=SUM(V0+V1+V2,3);
ZJ:=EMA(V3,4);
资金平衡线:0,COLORLIMAGENTA,LINETHICK1;
短线资金流:ZJ,COLORWHITE;
D:=ZJ-REF(ZJ,1);
资金流速:D,COLORGREEN;
{短线操作}
{清仓信号}
Z1:=REF(ZJ,1)>REF(ZJ,2) AND ZJ<REF(ZJ,1);
DRAWTEXT(Z1,ZJ,'减'),COLORGREEN;
{建仓信号}
Z2:=REF(ZJ,1)<=REF(ZJ,2) AND ZJ>REF(ZJ,1);
DRAWTEXT(Z2,ZJ,'加'),COLORRED;
658588127.jpg
|