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

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[通达信] 通达信突破大涨指标公式源码


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

VAR1:=MAX(OPEN,CLOSE);
VAR2:=MIN(OPEN,CLOSE);
VAR3:=REF(HHV(HIGH,2),1);
VAR4:=REF(LLV(LOW,2),1);
VAR5:=IF(VAR1>VAR3,1,IF(VAR2<VAR4,-1,0));
VAR6:=BARSLAST(VAR5=0);
VAR7:=REF(REF(HIGH,BARSLAST(VAR5=1)),VAR6);
VAR8:=REF(REF(LOW,BARSLAST(VAR5=-1)),VAR6);
VAR9:=IF(VAR5=1,IF(VAR1>VAR7,1,0),IF(VAR5=-1,IF(VAR2<VAR8,-1,0),0));
VAR10:=BARSLAST(VAR9=-1);
VAR11:=BARSLAST(VAR9=1);
VAR12:=REF(COUNT(crOSS(VAR9,-0.5),VAR11),VAR10);
VAR13:=COUNT(CROSS(VAR9,0.5),VAR10);
VAR14:=IF(VAR9=1,IF(VAR13=1,IF(VAR12>0,1,0),0),0);
VAR15:=VALUEWHEN(VAR14,REF(REF(HIGH,VAR11),VAR10));
VAR16:=100*Abs(C-VAR15)/VAR15<10;
VAR17:=EMA(CLOSE,18)-EMA(CLOSE,40);
VAR18:=EMA(VAR17,3);
VAR19:=(VAR17-VAR18)*2;
VAR20:=VAR19#DAY;
VAR21:=VAR19#WEEK;
VAR22:=VAR19#MONTH;
VAR23:=VAR19#SEASON;
NOTEXT1:EMA((VAR20+VAR21*7+VAR22*31+VAR23*94)/133,5),LINETHICK2,COLORYELLOW,NODRAW;
STICKLINE(NOTEXT1>0,NOTEXT1,0,3,1),COLORRED;
STICKLINE(NOTEXT1<0,NOTEXT1,0,3,1),COLORCYAN;
NOTEXT2:REF(NOTEXT1/2,BARSLAST(NOTEXT1=HHV(NOTEXT1,120))),COLORRED,LINETHICK1;
NOTEXT3:REF(NOTEXT1/2,BARSLAST(NOTEXT1=HHV(NOTEXT1,250))),COLORWHITE,LINETHICK1;
VAR28:=NOT(REF(NOTEXT2,1)=NOTEXT2);
VAR29:=NOT(REF(NOTEXT2,1)=REF(NOTEXT3,1)) AND NOTEXT2=NOTEXT3 AND C>VAR15 AND VAR16;
STICKLINE(VAR28,0,NOTEXT1,2,0),COLORYELLOW;
STICKLINE(NOTEXT1>=NOTEXT3,NOTEXT3,NOTEXT1,2,0),COLORMAGENTA;
NOTEXT4:IF(HHVBARS(VAR19,90),REF(VAR19,HHVBARS(VAR19,90)),VAR19),COLORYELLOW,LINETHICK2;
NOTEXT5:IF(NOTEXT4>REF(NOTEXT4,1),NOTEXT4,DRAWNULL),COLORMAGENTA,LINETHICK4;
NOTEXT6:IF(NOTEXT4<REF(NOTEXT4,1),NOTEXT4,DRAWNULL),COLORGREEN,LINETHICK4;
DRAWTEXT(VAR29 AND NOTEXT4>NOTEXT3,-0.01,'↖突破大涨'),COLORYELLOW;





回复

举报

QQ|

GMT+8, 2024-11-16 11:32

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