飞狐另类均线主图指标公式

[复制链接]
查看202 | 回复0 | 2021-8-21 12:50:43 | 显示全部楼层 |阅读模式

{短线粘合背景}
Bj1:=hhv(ma(llv(h,2),8),6)*0.978;
Bj2:=WMA(C,7);
Tj1:=LLV(ma(L,12),4);
Tj2:=MA(Tj1,3);
FILLRGN(ABS(Tj1-Tj2)<0.008 AND C>Bj1 AND Bj2>REF(Bj2,1),Tj1,Tj2*0.98),COLORGRAY;//背景
{开盘既知今天高低价}
Vg:=MA(REF(H,1)/REF(C,2),27)*REF(C,1);
Vd:=MA(REF(L,1)/REF(C,2),27)*REF(C,1);
A5:=Vd[SYSPARAM(1)];
RA5:=Vd[SYSPARAM(1)-1];
A10:=Vg[SYSPARAM(1)];
RA10:=Vg[SYSPARAM(1)-1];
jt5:=if(A5>RA5,'↑','↓');
jt10:=if(A10>RA10,'↑','↓');
SZ1:='开盘测最高:'+NUMTOSTR(Vg[SYSPARAM(1)],2)+jt10;
SZ2:='\n \n开盘测最低:'+NUMTOSTR(Vd[SYSPARAM(1)],2)+jt5;
{股旁网-股票公式网站 www.gupang.com}
{K线}
STICKLINE(O>=C,C,O,7,0 ),ColorFFDBAB;
STICKLINE(O>=C,H,L,0,0),ColorFFDBAB;
STICKLINE(C>=O,C,O,7,1),COLORRED;
STICKLINE(C>=O,C,H,0,0),COLORRED;
STICKLINE(C>=O,L,O,0,0),COLORRED;
{合线}
T1:=ma(C,73);
T2:=MA(L,42);
合1:ema(EMA(T1,2),3),PRECISION2,LINETHICK2,COLORGREEN;
合2:REF(EMA(T2,11),9),PRECISION2,LINETHICK2,COLORMAGENTA;
{趋势}
HZFX:=forcast(HHV((C+L)/2,1),13);
HZFD:(LLV(HZFX,2)/HZFX)*LLV(HZFX,2),LINETHICK2,Color0089FF;
PARTLINE(HZFX<=HZFD,HZFD),LINETHICK3,ColorCF7165;
{乖离线}
TZAA:=C-REF(EMA(L,13),1)+(C*0.928);
乖离:MA(TZAA,3),PRECISION2,ColorBBFFFF;{抄底参考用}
顶:LLV(HHV(乖离,35),2),PRECISION2,LINETHICK2,Color008987;//逃顶线
底:((LLV(L,36)*0.88)*0.88),LINETHICK2,PRECISION2,COLOR009900;
{J小于底是底部;如果乖离同时小于MACD零轴,底部的概率极大}
{MACD}
HS:=(LLV(L,36)*0.868);
DIF:=EMA(C,12)-EMA(C,26);
DEF:=EMA(DIF,9);
MACD:=(4*(DIF-DEF));
stickline(MACD<0,MACD+HS,HS,1,0),colorDDDD66; stickline(MACD>ref(MACD,1) and MACD<0,MACD+HS,HS,1,0),ColorFFDBEA;
stickline(MACD>0,MACD+HS,HS,1,0),Color8ED1FF; stickline(MACD>ref(MACD,1) and MACD>0,MACD+HS,HS,1,0),colorred;
PARTLINE(MACD>0,HS),COLOR2266FF,LINETHICK2; PARTLINE(MACD<0,HS),COLORDDDD66,LINETHICK2;
{kdj}
RSV:=(C-LLV(L,19))/(HHV(H,19)-LLV(L,19))*10;
K:=(SMA(RSV,3,1)+HS*18)/20;
D:=SMA(K,3,1);
//PARTLINE(C,D),ColorBE9A00;
J:3*K-2*D,PRECISION2,COLORYELLOW;
{时间}
variable:wday[7]='星期六';
wday[1]:='星期日';
wday[2]:='星期一';
wday[3]:='星期二';
wday[4]:='星期三';
wday[5]:='星期四';
wday[6]:='星期五';
fy:=year;
fm:=month;
fd:=day;
wd:=weekday;
p:=sysparam(1);
str1:='今日: '+numtostr(fy[p],0)+'年'+numtostr(fm[p],0)+'月'
+numtostr(fd[p],0)+'日 '+wday[wd[p]+1];
DRAWTEXT(BARPOS=SYSPARAM(2),C,str1),ALIGN5,Color008987;
{开盘既知今天高低价}
DRAWTEXT(BARPOS=SYSPARAM(2),c,SZ1),align4,COLORYELLOW;
DRAWTEXT(BARPOS=SYSPARAM(2),c,SZ2),align4,COLORCYAN;

202108211228.jpg

202108211228.jpg

 

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则