通达信T+0的好帮手组合分时 源码
本指标是在牛牛指标聚宝同学的“分时低部、顶部”和秀山腾龙班长的“腾龙分时”的基础上组合、发展起来的,在此对原作者表示感谢!亦希望我的加工能对各位同学做T+0摊薄成本有所帮助!具体用法就不多说了,各位同学请自行琢磨领悟。源码如下:
- {组合分时}
- A1:=(EMA(C,5)+EMA(C,15))/2;
- B1:=(EMA(C,30)+EMA(C,60))/2;
- C1:=SUM(C*V,(BARSSINCE(V>0)+1))/SUM(V,(BARSSINCE(V>0)+1))+((BARSSINCE(V>0)+1)*0);
- D1:=(C1+DYNAINFO(5))/2;
- E1:=(C1+DYNAINFO(6))/2;
- 振幅:=DYNAINFO(13)*100;
- 线幅1:=ABS((D1-B1)/B1)*100;
- 上涨幅:=ABS((D1-REF(D1,1))/REF(D1,1))*100;
- 线幅2:=ABS((C1-B1)/B1)*100;
- 均涨幅:=ABS((C1-REF(C1,1))/REF(C1,1))*100;
- 线幅3:=ABS((E1-B1)/B1)*100;
- 下涨幅:=ABS((E1-REF(E1,1))/REF(E1,1))*100;
- 慢线幅:=ABS((B1-REF(B1,1))/REF(B1,1))*100;
- 上差:=ABS(C1-D1);
- 下差:=ABS(C1-E1);
- 偏下:=COUNT(下差*3<上差,15)=15;
- 偏上:=COUNT(上差*3<下差,15)=15;
- 下横:=(COUNT(线幅2<0.15,10)=10 AND COUNT(均涨幅<0.01,10)=10 AND COUNT(慢线幅<0.01,5)=5) OR (COUNT(线幅3<0.15,10)=10 AND COUNT(下涨幅<0.01,10)=10 AND COUNT(慢线幅<0.01,5)=5);
- 上横:=(COUNT(线幅1<0.15,10)=10 AND COUNT(上涨幅<0.01,10)=10 AND COUNT(慢线幅<0.01,5)=5) OR (COUNT(线幅2<0.15,10)=10 AND COUNT(均涨幅<0.01,10)=10 AND COUNT(慢线幅<0.01,5)=5);
- 上突:=偏下 AND 下横;
- 下破:=偏上 AND 上横;
- 标准1:=COUNT(B1<E1,15)=15 AND COUNT(B1<REF(B1,1),15)=15;
- 标准2:=COUNT(B1<E1,20)=20 AND COUNT(B1<REF(B1,1),15)=20;
- 标准3:=COUNT(B1<E1,25)=25 AND COUNT(B1<REF(B1,1),20)=25;
- 低位:=IF(振幅>=5,标准3,IF(振幅<5 AND 振幅>=3,标准2,标准1));
- DRAWBAND(D1,RGB(75,0,0),C1,0);
- DRAWBAND(C1,RGB(0,75,0),E1,0);
- STICKLINE(低位,E1,D1,0,0),COLORYELLOW;
- STICKLINE(上突,E1,C1,0,0),COLORRED;
- STICKLINE(下破,D1,C1,0,0),COLORGREEN;
- 均价:C1,COLORYELLOW,LINETHICK2;
- 上轨:D1,COLORRED,POINTDOT;
- 下轨:E1,COLORGREEN,POINTDOT;
- 回调认同:EMA(EXPMA(C,20),13),COLOR004B00;
- STICKLINE(回调认同>均价,回调认同,均价,1,0),COLORFF00FF;
- STICKLINE(回调认同<=均价,回调认同,均价,1,0),COLOR00B400;
- AAA:=MAX(DYNAINFO(3),DYNAINFO(5));
- BBB:=MIN(DYNAINFO(3),DYNAINFO(6));
- CCC:=AAA-BBB;
- 中轨:=(AAA+BBB)/2,COLOR999900;
- 阻力:BBB+CCC*7/8,COLORBLUE;
- 支撑:BBB+CCC*1/8,COLORFF00FF;
- 上顶:BBB+CCC*2/3,COLOR999900;
- 下底:BBB+CCC/3,COLOR999900;
- 价:C,COLORFFFFFF;
- STICKLINE(价>阻力,阻力,价,2,0),COLORRED;
- STICKLINE(价<支撑,支撑,价,2,0),COLORGREEN;
-
E474122521.png
|