当前位置:首页 > 通达信公式 > 内容

通达信量化建仓,看趋势 监测主力进出源码主图

作者:公式网   更新时间:2023-09-04   点击:


量化建仓

1.股价高于平均线,视为强势;股价低于平均线,视为弱势
2.平均线向上涨升,具有助涨力道;平均线向下跌降,具有助跌力道;
3.二条以上平均线向上交叉时,买进;
4.二条以上平均线向下交叉时,卖出;
5.移动平均线的信号经常落后股价,若以EXPMA、VMA辅助,可以改善。
X1:=(C+L+H)/3;
X2:=EMA(X1,6);
X3:=EMA(X2,5);
做空:IF(SAR(10,2,20)>=H,SAR(10,2,20),DRAWNULL),CIRCLEDOT,COLOR80FF00;
做多:IF(SAR(10,2,20)<=L,SAR(10,2,20),DRAWNULL),CIRCLEDOT,COLORRED;
主力操盘线:=EMA(EMA(EMA(CLOSE,2),2),2);
趋势线:(MA(主力操盘线,5)),COLORGREEN,LINETHICK2;
IF(趋势线>REF(趋势线,1),趋势线,DRAWNULL),COLORFF00FF,LINETHICK2;
IF(趋势线< REF(趋势线,1),趋势线,DRAWNULL),COLORGREEN,LINETHICK2;
MA5:MA(CLOSE,5),COLOR8000FF,DOTLINE;
MA10:MA(CLOSE,10) ,COLOR8080FF,DOTLINE;
MA5下跌显示值:IF(MA5< REF(MA5,1),MA5,DRAWNULL),COLOR80FF80,DOTLINE;
MA10下跌显示值:IF(MA10< REF(MA10,1),MA10,DRAWNULL),COLOR00FF00,DOTLINE;
趋势线上升显示:IF(趋势线>REF(趋势线,1),趋势线,DRAWNULL),LINETHICK2,COLOR8000FF;
前期低:REF(O,BARSLAST(LLV(C,20)=C)),COLORFFFFFF,NODRAW;
STICKLINE(L,前期低,前期低,2,0),COLOR808040;
标钱袋:DRAWICON(CROSS(C,前期低),L,11);
DRAWNUMBER(ISLASTBAR,前期低,前期低);
STICKLINE(CROSS(C,前期低),C,O,3,0),COLOR1D7DC5;
STICKLINE(C/REF(C,1)>1.097,C,O,3,0),COLORYELLOW;
TC1:=IF(H=HHV(H,48),H,DRAWNULL);
TC2:=CONST(BARSLAST(TC1=H))+1;
UPPER1:=CONST(IF(TC2=1,H,REF(H,TC2-1)));
BC1:=IF(L=LLV(L,48),L,DRAWNULL);
BC2:=CONST(BARSLAST(BC1=L))+1;
LOWER1:=CONST(IF(BC2=1,L,REF(L,BC2-1)));
LP:=CURRBARSCOUNT<=BC2 AND L=LOWER1;
HP:=CURRBARSCOUNT<=TC2 AND H=UPPER1;
DRAWTEXT(LP,L*0.982,'底背'),COLOR00FFFF;
DRAWTEXT(HP,H*1.00,' 波段顶'),COLOR00FF80;
LCC:=REF(CLOSE,1);
RSIC:=SMA(MAX(CLOSE-LCC,0),6,1)/SMA(ABS(CLOSE-LCC),6,1)*100;
DRAWTEXT(CROSS(84,RSIC) , HIGH*0.99,' 卖出'),COLOR00FF00;
日:=150;
昨前:=3;
高1:=REF(HHV(H,日),昨前);
天顶:REFDATE(高1,DATE)NODRAW,COLORCYAN;
顶:=REFDATE(高1,DATE);
极顶:=REFDATE(顶,DATE);
跑:=极顶=H AND ((C-L)< (O-C) OR (O-L)< (C-O));
STICKLINE(跑,C,O,3,0),COLORE12F00;
STICKLINE(跑,L,H,0.1,0),COLORE12F00;
DRAWTEXT(跑,H*0.96,'---到顶')COLOR00FF00;
DRAWICON(SAR(10,2,20)<=L AND REF(SAR(10,2,20)>=H,1),REF(MIN(C,O),1),42);
DRAWICON(SAR(10,2,20)>=H AND REF(SAR(10,2,20)<=L,1),HHV(H,10),43);

通达信量化建仓,看趋势 监测主力进出源码主图

通达信量化建仓,看趋势 监测主力进出源码主图

资源下载

相关文章

热门推荐

移动端首页 | PC端

© by gszx.com.cn Mobile Web