龙听期货论坛's Archiver

龙听 发表于 2018-10-19 15:57

[转载]通达信【BOLL-金】副图

【注意】---------------你的【通达信版本】必需能够用函数 WMA. 和 DRAWGBK(O>C,RGB(40,0,40),RGB(0,50,40),0,'01',0);否侧你就得提高你的版本--------
公式源码下:---------------------------------------------
[code]
{BOLL-金F}
DRAWGBK(O>C,RGB(40,0,40),RGB(0,50,40),0,'01',0);
{1.重心线}
HH:=HHV(H,3);LL:=LLV(L,3);
ZXC:=WMA((2*C+HH+LL)/4,4);
ZXO:=REF(ZXC,1);
ZXC,COLOR00FF00,LINETHICK2;

IF(ZXC>REF(ZXC,1),ZXC,DRAWNULL),COLORRED,LINETHICK3;
{2.重心K线--------可以加减大括弧-------}
STICKLINE(ZXO>=ZXC,ZXO,ZXC,3,0 ),COLOR003300;
STICKLINE(ZXO>=ZXC,ZXO,ZXC,2,0 ),COLOR005500;
STICKLINE(ZXO>=ZXC,ZXO,ZXC,1,0 ),COLOR007700;
STICKLINE(ZXO>=ZXC,ZXO,ZXC,0.5,0 ),COLOR009900;

STICKLINE(ZXO
STICKLINE(ZXO
STICKLINE(ZXO
STICKLINE(ZXO
{3.BOLL-金}
MID:MA(ZXC,18),COLOR00FFFF,DOTLINE;
UPPER:MID + 1.8*STD(ZXC,18),COLORFF66FF;
LOWER:MID - 1.8*STD(ZXC,18),COLORFF9900;
{4.高抛.低吸}
RC:=(H+L+C*2)/4;
R2D:=WMA(RC,27);
R2E:=STD(RC,27);
R3F:=(RC-R2D)/R2E*100;
R40:=WMA(R3F,3);
R41:=WMA(R40,3);
JD:=WMA(R41,2);
AJ:=3*R41-2*JD;
DRAWTEXT(CROSS(AJ,JD) ,L-0.2,'←买呗'),COLOR00FFFF,LINETHICK2;
DRAWTEXT(CROSS(JD,AJ) ,H+0.2,'←跑哇'),COLOR00FFFF,LINETHICK2;
[/code]

[attach]4628[/attach]

页: [1]