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

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[飞狐] 仓位增减+乖离率差


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



{仓位增减}
空:=EMA(C,5);
均衡:EMA(空,5),COLORWHITE;
中轨:HHV(MA(H,13),13),COLORyellow,LINETHICK1;
趋势:LLV(MA(H,13),1),COLORred,LINETHICK1;
varA:=(CLOSE-REF(OPEN,29))/REF(OPEN,29)*100;
varB:=EMA(0.667*REF(varA,1)+0.333*varA,5);
DRAWTEXT(IF(VOL>=1.3*MA(VOL,5)ANDCOUNT(varA>=varBANDvarA<-17,3)ANDREF(LOW,1)=LLV(LOW,120),1,0),LOW,'买入');
varC:=SMA(MAX(CLOSE-REF(C,1),0),6,1)/SMA(ABS(CLOSE-REF(C,1)),6,1)*100;
var1:=(HIGH+LOW+OPEN+2*CLOSE)/5;
var2:=REF(var1,1);
var3:=SMA(MAX(var1-var2,0),10,1)/SMA(ABS(var1-var2),10,1)*100;
var4:=FILTER(IF(COUNT(var3<20,5)>=1ANDCOUNT(var1=LLV(var1,10),10)>=1ANDCLOSE>=OPEN*1.038ANDVOL>MA(VOL,5)*1.2,1,0),5);
DRAWICON(var4,LOW,1);
var5:=FILTER(均衡>REF(均衡,1)AND中轨REF(C,1),11);
DRAWTEXT(var5,Low*0.985,'加仓'),COLORyellow;
DRAWTEXT(var5,Low*0.995,'^'),COLORyellow;
var6:=REF(CLOSE,1);
var7:=SMA(MAX(CLOSE-var6,0),6,1)/SMA(ABS(CLOSE-var6),6,1)*100;
DRAWTEXT(CROSS(84,var7),H*1.035,'减仓'),COLOR00FF00;
DRAWTEXT(CROSS(84,var7),H*1.015,'◇'),COLOR00FF00;

{乖离率差}
BIAS1:(CLOSE-MA(CLOSE,L1))/MA(CLOSE,L1)*100;
BIAS2:HHV((CLOSE-MA(CLOSE,L1))/MA(CLOSE,L1)*100,L2);






回复

举报

QQ|

GMT+8, 2024-11-17 10:34

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