股资源-股票学习站-学炒股-股票课程-炒股教程-分析选股指标-入门基础知识

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[通达信] 通达信趋势信号指标公式(源码、主图)


    [-----复制链接-----]
楼主
 通达信源码安装路径:1,工具栏点击公式选项。2,弹出公式窗口点击新建。3,把源码复制到指标编辑器保存。4,回到K线图界面安装建立好的公式 || 2020-1-1 11:01:09
[通达信] 通达信趋势信号指标公式(源码、主图)

QWX1:=HHV(CLOSE,30);

QWX2:=LLV(CLOSE,30);

QWX3:=CONST((QWX1+QWX2)/2);

QWX4:=ABS((2*CLOSE+HIGH+LOW)/4-MA(CLOSE,20))/MA(CLOSE,20);

QWX5:=CONST((1-7/100)*(DMA(CLOSE,QWX4)));

QWX6:=CONST((1+7/100)*(DMA(CLOSE,QWX4)));

{KDJ}

RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;

KX:=SMA(RSV,3,1);

DX:=SMA(KX,3,1);

JX:=3*KX-2*DX;

{MACD}

DIF:=(EMA(CLOSE,12)-EMA(CLOSE,26))*2+QWX3,COLORWHITE;

DEA:=EMA(DIF,9),COLORYELLOW;

MCD:=(DIF-DEA)*2+QWX3;

DRAWBAND(MCD,RGB(120,0,100),QWX3,RGB(60,100,50));

DRAWKLINE(HIGH,OPEN,LOW,CLOSE);

牛熊线:(EMA(CLOSE,30)+EMA(CLOSE,72))/2,LINETHICK2,COLORRED;

M5:MA(CLOSE,5),COLORWHITE;

M10:MA(CLOSE,10),COLORYELLOW;

M20:MA(CLOSE,20),COLORFF00FF;

M60:=MA(CLOSE,60),COLOR6699CC;

VAR1:=IF(CLOSE>OPEN,CLOSE,OPEN);

VAR2:=MEMA(CLOSE,5);

VAR3:=ATAN((VAR2/REF(VAR2,1)-1)*100);

VAR4:=IF(VAR3>0,VAR3,VAR3);

VAR5:=(CLOSE/REF(CLOSE,1)-1)*100;

VAR6:=VAR5<1.5 AND VAR5>-1.5;

今日之升★:LAST(VAR6,4,1) AND VAR5>2 AND VOL>REF(VOL,1),NODRAW,COLORYELLOW;

DRAWTEXT(今日之升★,L/1.01,'★'),COLORYELLOW;

强势:IF(VAR4>=REF(VAR4,1) AND VAR4>=0,M10,DRAWNULL),COLORRED,LINETHICK2;

整理:IF(VAR4<REF(VAR4,1) AND VAR4>0,M10,DRAWNULL),COLORGREEN,LINETHICK2;

支撑:IF(PERIOD=5,IF(BARSLAST(CURRBARSCOUNT=5),QWX5,DRAWNULL),DRAWNULL),COLORCYAN;

阻力:IF(PERIOD=5,IF(BARSLAST(CURRBARSCOUNT=5),QWX6,DRAWNULL),DRAWNULL),COLORYELLOW;

{柱型显示}

STICKLINE(CLOSE>REF(CLOSE,1)*1.0985 AND CLOSE=HIGH,CLOSE,OPEN,4,-1),COLOR00FFFF;

STICKLINE(CLOSE<REF(CLOSE,1)*0.9015 AND CLOSE=LOW,CLOSE,OPEN,4,-1),COLORGREEN;

{蓝}

STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,3,0),COLORFF7700;

STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,2.2,0),COLORFF9900;

STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,1.5,0),COLORFFBB00;

STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,0.5,0),COLORCYAN;

{红}

STICKLINE(CLOSE>OPEN,CLOSE,OPEN,3,0),COLOR000099;

STICKLINE(CLOSE>OPEN,CLOSE,OPEN,2.2,0),COLOR0000CC;

STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1.5,0),COLOR0000FF;

STICKLINE(CLOSE>OPEN,CLOSE,OPEN,0.5,0),COLORCC66FF;

{绿}   

STICKLINE(CROSS(M5,EMA(C,3)),VAR1,(OPEN+CLOSE)/2,3,0),COLOR009900;

STICKLINE(CROSS(M5,EMA(C,3)),VAR1,(OPEN+CLOSE)/2,2.2,0),COLOR00BB00;  

STICKLINE(CROSS(M5,EMA(C,3)),VAR1,(OPEN+CLOSE)/2,1.5,0),COLOR00DD00;     

STICKLINE(CROSS(M5,EMA(C,3)),VAR1,(OPEN+CLOSE)/2,0.5,0),COLOR00FF00;

{灰}

STICKLINE(CROSS(EMA(C,3),M5),OPEN,(OPEN+CLOSE)/2,3,0),COLOR999999;

STICKLINE(CROSS(EMA(C,3),M5),OPEN,(OPEN+CLOSE)/2,2.2,0),COLORBBBBBB;      

STICKLINE(CROSS(EMA(C,3),M5),OPEN,(OPEN+CLOSE)/2,1.5,0),COLORDDDDDD;     

STICKLINE(CROSS(EMA(C,3),M5),OPEN,(OPEN+CLOSE)/2,0.5,0),COLORFFFFFF;

STICKLINE(CROSS(JX,DX),OPEN,CLOSE,0.5,0),COLORYELLOW;

STICKLINE(CROSS(DX,JX),OPEN,CLOSE,0.5,0),COLOR000099;

{量能平台}

HIGHN1:=10;LOWN1:=10;HIGHDISPLAY1:=0;LOWDISPLAY1:=0;ZGDISPLA1Y:=0;MADISPLAY1:=0;

AAX:=REF(VOL,HIGHN1)=HHV(VOL,2*HIGHN1+1);

QYX:=BACKSET(AAX,HIGHN1+1);

CCX:=FILTER(QYX,HIGHN1) AND VOL=HHV(VOL,HIGHN1+1);

DRAWICON(CCX,C*1.02,2);

DDDX:=BARSLAST(CCX);

GDTSX:=IF(CCX,CURRBARSCOUNT,0);

DINGBUX:=IF(DDDX,REF(VOL,DDDX),C);{顶部}

DINGBUTSX:=IF(DDDX,REF(GDTSX,DDDX),GDTSX);

DINGBU1X:=REF(DINGBUX,DDDX+1);

GDCS1X:=CONST(DINGBUTSX);

DINGBUTS1X:=REF(DINGBUTSX,DDDX+1);

GDCS2X:=CONST(DINGBUTS1X);

DINGBU2X:=REF(DINGBU1X,DDDX+1);

MMX:=IF(CURRBARSCOUNT>GDCS2X,0,0);

DRAWLINE(CURRBARSCOUNT=GDCS2X,C,ISLASTBAR,REF(C,GDCS2X-1),1),COLOR0055FF,

LINETHICK1;

DRAWLINE(CURRBARSCOUNT=GDCS1X,C,ISLASTBAR,REF(C,GDCS1X-1),1),COLORYELLOW,LINETHICK1;




065237pcplq5qb2sc4hhx4.png


回复

举报

QQ|

GMT+8, 2024-11-17 00:21

快速回复 返回顶部 返回列表