通达信分时图(源码、副图、贴图)介绍
通达信分时图(源码、副图、贴图)
坐了半天,把两个高手的粘合思路组合为一个分时公式,一个主要看趋势,一个主要看节奏,会用了是可以进到低点抛到高点的,观者可以自己再体会一下。对分时在箱体大幅震荡的,做高抛低吸有用.希望高手再做优化,这个不能预测当天的最高点和最低点,只能看相对的高低点。
源码如下:
X1:=(C+L+H)/3;BB13:=ATAN(EMA(X1,13)-REF(EMA(X1,13),1))*3.1416*10;
EMA8:=EMA(C,8);DRAWTEXT(FILTER(BB13>1 AND EMA(X1,13)>REF(EMA(X1,8),1),10),
EMA8,'∠45'),COLORWHITE;
短线:DMA(MA(CLOSE+REF(CLOSE,5)/CLOSE*0.098,1),VOL),COLORYELLOW;
中1线: DMA(MA(CLOSE+REF(CLOSE,5)/CLOSE*0.098,6),VOL),COLOR006EFF;
中2线:DMA(MA(CLOSE+REF(CLOSE,5)/CLOSE*0.098,8),VOL),COLORWHITE;
中3线: DMA(MA(CLOSE+REF(CLOSE,5)/CLOSE*0.098,10),VOL),COLORGREEN;
长线: DMA(MA(CLOSE+REF(CLOSE,5)/CLOSE*0.098,34),VOL),COLORBLUE;
日时转换:=IF(PERIOD=5,120,240);
QZS:=(EMA(CLOSE,10)+EMA(CLOSE,32))/2;
VAR1:=(EMA(CLOSE,30)+EMA(CLOSE,72))/2;
VAR2:=(EMA(VOL,10)+EMA(VOL,32))/2;
VAR3:=(VAR1+VAR2)/2;
VAR4:=EMA(VAR3,30);
VAR5:=EMA(VAR3,60);
VAR6:=EVERY(VAR1>REF(VAR1,1),5) AND EVERY(VAR4>REF(VAR4,1),5);
DRAWBAND(VAR1,RGB(150,30,30),EMA(VAR1,60),RGB(0,110,30));
牵引线:VAR1,COLORYELLOW;
强弱线:EMA(VAR1,日时转换),POINTDOT,COLORWHITE;
趋势关注:IF(CROSS(VAR1,EMA(VAR1,60)) AND VAR6,1,0),NODRAW,COLORRED;
量价关注:IF(CROSS(VAR3,VAR5) AND VAR6,1,0),NODRAW,COLORWHITE;
冲击量:IF(VAR3>VAR5 AND VAR6,1,0),NODRAW,COLORYELLOW;
强势区:IF(VAR1>强弱线,1,DRAWNULL),NODRAW,COLORRED;
止损区:IF(VAR1<强弱线,1,DRAWNULL),NODRAW,COLORGREEN;
STICKLINE(QZS>VAR1,QZS,VAR1,1,0),COLORMAGENTA;
STICKLINE(冲击量=1,QZS,VAR1,1,0),COLORYELLOW;
DRAWICON(趋势关注=1,EMA(VAR1,60),13);
DRAWTEXT(量价关注=1,EMA(VAR1,60),'L0V'),COLORWHITE;
gd14091