【通达信源码分享】OBV趋势图,是OBV优化版本有用法说明(副图 源码 测试图)
通达信免费指标
09-21
阅读:1136
评论:0
OBV趋势图
极品OBV优化后,起名OBV趋势图
公式的用法:
黄柱持股,绿柱走人,粉红柱观察。顺势而为,惊喜不断。
{OBV趋势图}
{极品OBV M 1 100 13 N 1 100 5}
DRAWGBK(C>0,RGB(0,120,0),RGB(0,70,0),0,' ',0);
VA:=IF(CLOSE>REF(CLOSE,1),VOL,-VOL);
OBV1:=SUM(IF(CLOSE=REF(CLOSE,1),0,VA),0);
MA130:=MA(OBV,13);
DRAWBAND(MA130,RGB(0,0,80),OBV1,RGB(160,0,000));
A1:=REF(OBV1,5)=HHV(OBV1,2*5+1);
B1:=FILTER(A1,5);
C1:=BACKSET(B1,5+1);
D1:=FILTER(C1,5);
T线:=REF(OBV,BARSLAST(D1)),COLORFFFF00,NODRAW;
{STICKLINE(C>0,T线,T线,6,0),COLORFFFF00;
DRAWICON(CROSS(OBV,T线),T线*0.99,1);}
OBV:SUM(IF(CLOSE=REF(CLOSE,1),0,VA),0),COLOR00FFFF;
MOBV:MA(OBV,13),COLORFF00FF;
AAAA:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));
主动买盘:=IF(CLOSE>OPEN,AAAA*(HIGH-LOW),IF(CLOSE<OPEN,AAAA*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2));
主动卖盘:=IF(CLOSE>OPEN,AAAA*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,AAAA*(HIGH-LOW),VOL/2));
买占比:=主动买盘/(主动买盘+主动卖盘)*100;
WJ:=(HIGH+LOW+CLOSE)/3;
VD1:=IF(HIGH=LOW,1,HIGH-MAX(OPEN,CLOSE));
VD2:=IF(HIGH=LOW,1,MAX(CLOSE,OPEN)-WJ);
VD3:=IF(HIGH=LOW,1,MIN(OPEN,CLOSE)-LOW);
VD4:=IF(HIGH=LOW,1,WJ-MIN(CLOSE,OPEN));
VD5:=VOL/IF(HIGH=LOW,4,HIGH-LOW);
VD6:=(VD1*VD5);VD7:=(VD2*VD5);VD8:=(VD3*VD5);VD9:=(VD4*VD5);
买入量:=(VD9+VD8);卖出量:=(VD6+VD7);
买入资金:=买入量*CLOSE/100;卖出资金:=卖出量*CLOSE/100;
ZIF:=EMA(OBV,12)-EMA(OBV,26);
ZEA:=EMA(ZIF,9);
ZBC:=2*(ZIF-ZEA);
ZJS:=1.25*ZIF-0.25*ZEA;
ZQS:(ZJS*13*27-27*11*EMA(C,12)+13*25*EMA(C,26))/28,COLORFFFFFF,NODRAW;
FX:=(ZIF*13*27-27*11*EMA(C,12)+13*25*EMA(C,26))/28,COLORYELLOW,DOTLINE;
FQS:(ZEA*13*27-27*11*EMA(C,12)+13*25*EMA(C,26))/28,COLORFFFFFF,NODRAW;
PHX:=(ZQS+FQS)/2,COLORMAGENTA;
ZFC:ZQS-FX,COLOR00FFFF,NODRAW;
FPX:=FX-PHX;
STICKLINE(C,ZQS,FQS,1,1),COLORDD0000;
STICKLINE(ZQS>FQS,ZQS,FQS,1,0),COLOR000080;
STICKLINE(C,FX,PHX,1,1),COLORGREEN;
STICKLINE(FX>PHX,FX,PHX,1,0),COLOR00FFFF;
STICKLINE(FX>PHX AND FPX<REF(FPX,1),FX,PHX,1,0),COLOR00FF00;
STICKLINE(FX<PHX AND FPX>REF(FPX,1),FX,PHX,1,0),COLORLIRED;
DRAWBAND(ZQS,RGB(250,0,0),ZQS,RGB(250,0,0));
DRAWBAND(FQS,RGB(0,250,250),FQS,RGB(0,250,250));
版权声明
本文版权归掌上指标所有。
未经许可,不得转载,转载请注明出处!