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

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[飞狐] 飞狐 波段合成


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

以下是飞狐 波段合成

财务日期:FINANCE(0),LINETHICK0;
流通股亿:FINANCE(7)/10000,LINETHICK0;
税后利增%:FINANCE(54),LINETHICK0;
收益元:FINANCE(33),LINETHICK0;
市盈%:DYNAINFO(39),LINETHICK0;
{长波段}
MID:=MA(CLOSE,26);UPPER:=MID+2*STD(CLOSE,26);
LOWER:=MID-2*STD(CLOSE,26);布林截距:=(UPPER-LOWER)*100-200;
主升浪选股:=IF(CROSS(布林截距,-20)ANDMID>REF(MID,1),11,0),COLORgray;
主升浪:=IF(布林截距>0ANDMID>REF(MID,1)ANDREF(MID,1)>REF(MID,2),布林截距,0);
末跌段:=IF(布林截距>0ANDMID<REF(MID,1)ANDREF(MID,1)<REF(MID,2),布林截距,0)*-1;
画面起点:=SYSPARAM(2);画面终点:=SYSPARAM(3);画面K线数:=画面终点-画面起点+1;
时空最低:=LLV(末跌段,{画面K线数}400);时空视低:=时空最低[画面终点];
时空最高:=HHV(主升浪-时空视低,400{画面K线数});时空视高:时空最高[画面终点];
{新庄区}
Var1:=1/WINNER(CLOSE);Var2:=MA(CLOSE,13);
Var3:=100-ABS((CLOSE-Var2)/Var2*100);Var4:=LLV(LOW,75);
Var5:=HHV(HIGH,75);Var6:=(Var5-Var4)/100;Var7:=SMA((CLOSE-Var4)/Var6,20,1);
Var8:=SMA((OPEN-Var4)/Var6,20,1);Var9:=3*Var7-2*SMA(Var7,15,1);
VarA:=3*Var8-2*SMA(Var8,15,1);VarB:=100-VarA;
VarC:=IF(900101<DATEANDDATE<99991230,1,0);
新庄区:(100-IF(Var1>5,IF(Var1<100,Var1,Var3-10),0))*VarC*时空视高/100,COLOR0000dd;
FILLRGN(新庄区<时空视高,新庄区,时空视高*0.995),COLOR600030;


{空跌
var910:=100*(c-cost(10))/cost(10);
空跌幅度:if(var910<0,var910,0),coloryellow,linethick0;
空跌:=视高+空跌幅度*视高/20,linethick0,COLOR008800;
FILLRGN(空跌<视高,if(空跌<视高*0.6,视高*0.6,空跌),视高*0.999),COLOR005000;}

{长波段显示}
长升段:=主升浪-时空视低,COLOR553355,linethick2;
长跌段:=末跌段-时空视低,,COLOR553355,linethick2;
STICKLINE(长跌段=0-时空视低ANDNOT(长升段=0-时空视低),0-时空视低,长升段,10,1),COLOR000080;
STICKLINE(长升段=0-时空视低ANDNOT(长跌段=0-时空视低),0-时空视低,长跌段,10,1),colorAA5500;
0-时空视低,COLOR661166,linethick2;

{中波段}
VAR1:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*时空视高;
VAR2:=SMA(VAR1,3,1);VAR3:=SMA(VAR2,3,1);VAR4:=SMA(VAR3,3,1);
VAR5:=CROSS(VAR3,VAR4)ANDVAR3<20;VAR9:=CROSS(VAR4,VAR3)ANDVAR3>80;
VAR8:=CROSS(VAR2,VAR3)ANDVAR3>80ANDVAR3>VAR4;
AA:=LLV(LOW,36);BB:=HHV(HIGH,30);
中小心:87.5*时空视高/100,LINEDOT,COLORAA2200;
中跟踪:10*时空视高/100,LINEDOT,COLOR0000aa;
中波慢:=VAR3;
中波快:=((EMA(((CLOSE-AA)/(BB-AA))*(4),4))*(25))*时空视高/100,COLOR0055FF,LINETHICK1;
FILLRGN(中波快>VAR4,VAR4,中波快),COLOR000DD;FILLRGN(中波快<VAR4,VAR4,中波快),COLORf03000;
中波段:VAR4,COLOR0000DD,LINETHICK2;
{短波段}
短中枢:时空视高*0.5,LINEDOT,COLOR006600;
CS:=((CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100);
YJD:=(EMA(CS,3)-50)*2;YJF:=MA(YJD,5);
短波最低:=LLV(YJD,画面K线数);短波视低:=短波最低[画面终点];
STICKLINE((YJD-短波视低)*时空视高/180>(YJF-短波视低)*时空视高/180,(YJD-短波视低)*时空视高/180,(YJF-短波视低)*时空视高/180,1,0),COLOR00CCDD,linethick1,POINTDOT;
STICKLINE((YJD-短波视低)*时空视高/180<(YJF-短波视低)*时空视高/180,(YJD-短波视低)*时空视高/180,(YJF-短波视低)*时空视高/180,1,0),COLOR008800,linethick1,POINTDOT;
短波段:(YJD-短波视低)*时空视高/180,COLORff88ff,linethick1;
短波慢:(YJF-短波视低)*时空视高/180,COLOR00CCBB,linethick2; 






回复

举报

QQ|

GMT+8, 2024-11-15 10:39

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