立德趋势(通达信公式 主图 源码 测试图)

[复制链接]
查看30 | 回复0 | 2022-6-27 18:51:08 | 显示全部楼层 |阅读模式

 {立德趋势}

 
YXSJ:=18123099;
YX:=IF(1<1000000+YXSJ,1,0); 
;{指标有效期};
{==============以下一段显示板块信息==============}
WZ1:=STRCAT('所属行业:',HYBLOCK);
WZ2:=STRCAT('  所属地区:',DYBLOCK);
WZ3:=STRCAT('  题材:',GNBLOCK);
HB:=STRCAT(WZ1,WZ2);
题材概念:=STRCAT(HB,WZ3);
{DRAWTEXT_FIX(C>0 AND PERIOD=5,0.01,0,0,题材概念),COLORYELLOW;}
 
DRAWTEXT_FIX(YX=0,0.21,0.2,0,'系统崩溃,请删除重新安装'),COLORYELLOW;
 
}
UPX:="BOLL-M".UB;
LPX:="BOLL-M".LB;
 
XC:=O<BOLL.UB AND (O<EMA(C,250) OR O<MA(L,250))
AND  (O<MA(C,60) OR O<EMA(C,50) OR O<EMA(C,40)) 
AND (O<MA(C,120)  OR O<EMA(L,120))
AND (O<MA(C,20) OR O<EMA(C,40))
AND (C/REF(C,1)>1.09 OR C/O>1.09 OR C/L>1.095) AND C/L>1.03 
AND H>L AND H>O AND (C>=H*0.975 OR C/O>1.09)
AND H/L>=MA(H/L,10);
含金量:=SUM(XC AND PERIOD=5,300),NODRAW,COLORYELLOW;
DRAWICON(XC AND PERIOD=5,L*0.985,9);
 
M5:IF(显示趋势方向=0,MA(CLOSE,5),DRAWNULL),COLORWHITE;
M10:IF(显示趋势方向=0,MA(CLOSE,10),DRAWNULL),COLORYELLOW;
M20:IF(显示趋势方向=0,MA(CLOSE,20),DRAWNULL),COLORMAGENTA;
M60:IF(显示趋势方向=0,MA(CLOSE,60),DRAWNULL),COLORGREEN;
M120:IF(显示趋势方向=0,MA(CLOSE,120),DRAWNULL),COLORWHITE;
{M250:MA(C,250),COLOR009966,LINETHICK3;
IF((EMA(C,40)>MA(C,250) OR MA(C,60)>MA(C,250)), MA(C,250),DRAWNULL),COLORLIRED,LINETHICK3;
牛熊线:IF( MA(C,250)>=REF(MA(C,250),1) AND (EMA(C,40)>MA(C,250) OR MA(C,60)>MA(C,250)), MA(C,250),DRAWNULL),COLOR330099,LINETHICK3;
}
STICKLINE(显示趋势方向=1 AND YX=1 AND EMA(C,20)>EMA(C,40),EMA(C,20),EMA(C,40),1,0),COLORWHITE;
STICKLINE(显示趋势方向=1 AND YX=1 AND EMA(C,20)<=EMA(C,40),EMA(C,20),EMA(C,40),1,0),COLORCYAN;
STICKLINE(显示趋势方向=1 AND YX=1  AND EMA(C,20)>EMA(C,40) AND (EMA(C,40)>MA(C,250) OR EMA(C,40)>EMA(C,250)),EMA(C,20),EMA(C,40),1,0),COLOR6699FF;
STICKLINE(显示趋势方向=1 AND YX=1  AND EMA(C,20)<EMA(C,40) AND EMA(C,20)>MA(C,250),EMA(C,20),EMA(C,40),1,0),COLORFF9966;
 
STICKLINE(显示趋势方向=1 AND YX=1  AND EMA(C,20)<=EMA(C,40) AND EMA(C,40)<MA(C,250),EMA(C,20),EMA(C,40),1,0),COLORGREEN;
 
IF(显示趋势方向=1  AND YX=1 ,EMA(CLOSE,12),DRAWNULL),COLORWHITE;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)>EMA(C,40),EMA(CLOSE,12),DRAWNULL),COLORLIRED;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)>EMA(C,40) AND EMA(C,40)>MA(C,250),EMA(CLOSE,12),DRAWNULL),COLORRED;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)<EMA(C,40) AND EMA(C,40)<MA(C,250) ,EMA(CLOSE,12),DRAWNULL),COLORGREEN;
 
IF(显示趋势方向=1  AND YX=1 ,EMA(CLOSE,40),DRAWNULL),COLORWHITE,LINETHICK2;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)>EMA(C,40),EMA(CLOSE,40),DRAWNULL),COLORLIRED ,LINETHICK2;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)>EMA(C,40) AND (EMA(C,40)>MA(C,250) OR EMA(C,40)>EMA(C,250)),EMA(CLOSE,40),DRAWNULL),COLORRED,LINETHICK2;
IF(显示趋势方向=1  AND YX=1 AND EMA(C,12)<EMA(C,40) AND EMA(C,40)<MA(C,250),EMA(CLOSE,40),DRAWNULL),COLORGREEN,LINETHICK2;
 
 
DRAWKLINE(H,O,L,C);
RSILC:=REF(CLOSE,1);
RSI1:=SMA(MAX(CLOSE-RSILC,0),6,1)/SMA(ABS(CLOSE-RSILC),6,1)*100;
RSI2:=SMA(MAX(CLOSE-RSILC,0),12,1)/SMA(ABS(CLOSE-RSILC),12,1)*100;
RSI3:=SMA(MAX(CLOSE-RSILC,0),24,1)/SMA(ABS(CLOSE-RSILC),24,1)*100;
{=========}
ZXD:=60;ZXC:=130;ZXMID:=45;
ZXDIF:=EMA(CLOSE,ZXD)-EMA(CLOSE,ZXC),COLORRED,LINETHICK2;
ZXDEA:=EMA(ZXDIF,ZXMID),COLORWHITE;
ZXMACD:=(ZXDIF-ZXDEA)*2,COLORSTICK,LINETHICK3;
{================}
 
 
ZXEMAQJX:=BARSLAST(REF(CROSS(EMA(C,12),EMA(C,50)),1));
ZXEMAQSX:=BARSLAST(REF(CROSS(EMA(C,50),EMA(C,12)),1));
DXEMAQJX:=BARSLAST(REF(CROSS(EMA(C,12),EMA(C,26)),1));
DXEMAQSX:=BARSLAST(REF(CROSS(EMA(C,26),EMA(C,12)),1));
MACDQJX:=BARSLAST(REF(CROSS(MACD.DIF,MACD.DEA ),1));
MACDQSX:=BARSLAST(REF(CROSS(MACD.DEA,MACD.DIF),1));
 
EMA2JX:=((CROSS(EMA(C,12),EMA(C,50)) AND C>REF(C,ZXEMAQSX) AND C>REF(C,ZXEMAQJX)) OR (CROSS(EMA(C,12),EMA(C,26)) AND C>REF(C,DXEMAQJX) AND C>REF(C,DXEMAQSX)))
AND COUNT(HHV(H,60)/LLV(L,60)>1.38,60)=0
AND (EMA(C,50)>EMA(C,100) OR EMA(C,100)>EMA(C,250) OR MA(C,60)>MA(C,120) OR MA(C,120)>MA(C,250))
AND V>1 AND (MA(V,5)>MA(V,10) OR MA(V,10)>MA(V,60) OR EMA(V,20)>EMA(V,250)) AND YX=1;
 
{DRAWICON(EMA2JX AND PERIOD=5,EMA(L,50),1);
DRAWTEXT(EMA2JX  AND PERIOD=5,EMA(L,50),'金叉'),COLORWHITE;}
 
LT:=LLVBARS(L,60);
LTT:=BARSLAST(CURRBARSCOUNT=CONST(LT)+1);
HT:=FINDHIGHBARS(H,LT+1,60,1);
一元线:DRAWLINE(CURRBARSCOUNT=CONST(HT)+1,C,ISLASTBAR,REF(C,HT),0),COLORBLUE,LINETHICK2;
 
 
{==================}
{STICKLINE(YX=0 ,HHV(H,50),LLV(L,50),8,0),COLORBLUE;};
 

20204234423494017.png

20204234423494017.png
 

20204234424017234.png

20204234424017234.png

2020423442330886.rar

4.99 KB, 下载次数: 0

售价: 2 金钱  [记录]  [购买]

2020423442330886.rar

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则