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

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[通达信] 通达信K线深色主图指标公式源码


    [-----复制链接-----]
楼主
 通达信源码安装路径:1,工具栏点击公式选项。2,弹出公式窗口点击新建。3,把源码复制到指标编辑器保存。4,回到K线图界面安装建立好的公式 || 2024-6-24 12:31:04

{指标介绍: 1. 黄色:涨停; 2. 橙色:涨幅大于10个点未涨停; 3. 深橙:涨幅大于20个点未封板; 4. 绿色:跌停或跌幅大于10个点; 5. 浅紫:炸板阳线; 6. 深紫:炸板阴线; 7. 白色虚线:现价线。}

L1:=5; L2:=10; L3:=20; L4:=60; L5:=120; L6:=250; ZDJS:=IF(CODELIKE('880005'), 1, 0); M5:IF(ZDJS=0,MA(C,L1),DRAWNULL); M10:IF(ZDJS=0,MA(C,L2),DRAWNULL); M20:IF(ZDJS=0,MA(C,L3),DRAWNULL); M60:IF(ZDJS=0,MA(C,L4),DRAWNULL); M120:IF(ZDJS=0,MA(C,L5),DRAWNULL); M250:IF(ZDJS=0,MA(C,L6),DRAWNULL); {判断涨跌幅限制,涨跌停价格} CYB:=IF(FINANCE(3)=3, 1, 0); ZDF:=IF(FINANCE(3)=3 OR FINANCE(3)=4, 0.2, IF(FINANCE(3)=2, 0.3, IF(NAMEINCLUDE('ST'), 0.05, 0.1) ) ); ZT:=ZTPRICE(REF(CLOSE,1), ZDF); DT:=DTPRICE(REF(CLOSE,1), ZDF); ZT1:=ZTPRICE(REF(CLOSE,1), 0.1)+0.01; ZT2:=ZTPRICE(REF(CLOSE,1), 0.2)+0.01; DT1:=DTPRICE(REF(CLOSE,1), 0.1); DT2:=DTPRICE(REF(CLOSE,1), 0.2); {下一行是板块调用,也可以改为扩展数据调用,例如 EXTERNSTR(0,1) } DRAWTEXT_FIX(1,0,0, 0, STRCAT( HYBLOCK, STRCAT( ' + ', STRCAT( GNBLOCK, STRCAT(' + ', DYBLOCK) ) ) ) ),COLORWHITE; {DRAWTEXT_FIX(1,0,0,0, STRCAT(HYBLOCK,STRCAT(' + ', STRCAT(GNBLOCK,STRCAT('+ ', EXTERNSTR(0,1)))))),COLORWHITE;} N1:DRAWSL(ZDJS=1,3500,0,1000,1), COLORWHITE; N2:DRAWSL(ZDJS=1,750,0,1000,1), COLORWHITE; N:CONST(C), COLORWHITE, POINTDOT; W1:=3; W0:=0; NOCYB:=CYB=0 AND ZDJS=0; STICKLINE((NOCYB AND C<H AND H=ZT AND C>DT AND C<O), O, C, W1, 0), COLORFF4D88; STICKLINE((NOCYB AND C<H AND H=ZT AND C>O), O, C, W1, 0), COLORFF4DFF; GGR:=1200824; STICKLINE(DATE=GGR AND (CYB=1 OR CODELIKE('8808')), CONST(LLV(L,120)), CONST(HHV(H,120)), W0, 0),COLOR5C979C; STICKLINE((CYB=1 AND DATE<GGR AND C<ZT AND H=ZT AND C>DT AND C<O), O, C, W1, 0), COLORFF4DFF; STICKLINE((CYB=1 AND DATE<GGR AND C<ZT AND H=ZT AND C>O), O, C, W1, 0), COLORFF4DFF; STICKLINE((CYB=1 AND DATE>=GGR AND C<ZT AND H=ZT2 AND C>DT AND C<O), O, C, W1, 0), COLORFF4DFF; STICKLINE((C>ZT1 AND C<ZT2 AND C>O AND ZDJS=0), O, C, W1, 0), COLOR00AAFF; STICKLINE((C<H AND C>ZT2 AND C>O AND ZDJS=0), O, C, W1, 0), COLOR0066CC; STICKLINE((C<=DT1 AND C<O AND ZDJS=0), O, C, W1, 0), COLORGREEN; STICKLINE((NOCYB AND C+0.01>=ZT AND C=H), O, C, W1, 0),COLORYELLOW; STICKLINE((NOCYB AND C<=DT AND C=L), O, C, W1, 0),COLORGREEN; STICKLINE((NOCYB AND L<=DT AND C<ZT AND C>L), L, C, 0, 0),COLORGREEN;{曾跌停阳线} STICKLINE((CYB=1 AND DATE>=GGR AND C+0.01>=ZT2 AND C=H), O, C, W1, 0), COLORYELLOW; STICKLINE((CYB=1 AND DATE<GGR AND C+0.01>=ZT AND C=H), O, C, W1, 0), COLORYELLOW; STICKLINE((CYB=1 AND DATE<GGR AND C<=DT AND C=L), O, C, W1, 0), COLORGREEN;








回复

举报

QQ|

GMT+8, 2024-11-16 18:05

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