飞狐黄金分割副图指标

源码

K:=1;

{+}
input:K(1,1,3);   
DRAWGBK(1, COLORRGB(100,100,100),COLORRGB(50,50,50),0);

DRAWTEXT(BARPOS=SYSPARAM(2),HIGH,STKNAME+'     \n所属板块:  '+ BLKNAME),align4,COLORwhite;
STICKLINE(C>=O,C,O,8,0),COLOR0000AA;
STICKLINE(C>=O,C,O,6,0),COLOR0000bb ;
STICKLINE(C>=O,C,O,4,0),COLOR0000cc ;
STICKLINE(C>=O,C,O,2,0),COLOR0000ee;
STICKLINE(C>=O,H,L,0,0),COLOR0000ff;
STICKLINE(C<=O,C,O,8,0),Color7B7b00;
STICKLINE(C<=O,C,O,6,0),Color909000;
STICKLINE(C<=O,C,O,4,0),ColorA8a800;
STICKLINE(C<=O,C,O,2,0),COLORcece00;
STICKLINE(C<=O,H,L,0,0),COLORffff00;

n1:=sysparam(3);
n:=n1-sysparam(2)+1;
hh:=hhv(H,n);
ll:=llv(L,n);
最高:=hh[n1],COLORYELLOW;
PARTLINE(C and K<>3,最高),COLORYELLOW;
最低:ll[n1],COLORred;
PARTLINE(C and K<>3,最低),COLORred;
PARTLINE(C and K=1,最低+(最高-最低)*0.191),LINEDOT,COLORWHITE;
PARTLINE(C and K=1,最低+(最高-最低)*0.382),LINEDOT,COLORWHITE;
PARTLINE(C and K<>3,最低+(最高-最低)*0.5),COLORGREEN;
PARTLINE(C and K=1,最低+(最高-最低)*0.618),LINEDOT,COLORWHITE;
PARTLINE(C and K=1,最低+(最高-最低)*0.809),LINEDOT,COLORWHITE;
DRAWTEXT(BARSCOUNT(C)=SYSPARAM(3) and K<>3,REF(最低,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'最低↓'),ALIGN2,COLORred;
DRAWTEXT(BARSCOUNT(C)=SYSPARAM(3) and K<>3,REF(最高,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'最高↑'),ALIGN2,COLORYELLOW;

DRAWTEXT(BARPOS=SYSPARAM(2) and K=1,REF((最低+(最高-最低)*0.191)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'黄金 0.191↑'+NUMTOSTR(最低+(最高-最低)*0.191,2)),COLORWHITE;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=1,REF((最低+(最高-最低)*0.382)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'黄金 0.382↑'+NUMTOSTR(最低+(最高-最低)*0.382,2)),COLORWHITE;
DRAWTEXT(BARPOS=SYSPARAM(2) and K<>3,REF((最低+(最高-最低)*0.5)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'     50%  ↑'+NUMTOSTR(最低+(最高-最低)*0.5,2)),COLORGREEN;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=1,REF((最低+(最高-最低)*0.618)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'黄金 0.618↑'+NUMTOSTR(最低+(最高-最低)*0.618,2)),COLORWHITE;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=1,REF((最低+(最高-最低)*0.809)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'黄金 0.809↑'+NUMTOSTR(最低+(最高-最低)*0.809,2)),COLORWHITE;

PARTLINE(C and K=2,最低+(最高-最低)*1/8),LINEDOT,Color0095BC;
PARTLINE(C and K=2,最低+(最高-最低)*1/4),LINEDOT,Color0095BC;
PARTLINE(C and K=2,最低+(最高-最低)*3/8),LINEDOT,Color0095BC;
PARTLINE(C and K=2,最低+(最高-最低)*5/8),LINEDOT,Color0095BC;
PARTLINE(C and K=2,最低+(最高-最低)*7/8),LINEDOT,Color0095BC;
PARTLINE(C and K=2,最低+(最高-最低)*3/4),LINEDOT,Color0095BC;

DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*1/8)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 1/8↑'+NUMTOSTR(最低+(最高-最低)*1/8,2)),Color0095BC;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*1/4)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 1/4↑'+NUMTOSTR(最低+(最高-最低)*1/4,2)),Color0095BC;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*3/8)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 3/8↑'+NUMTOSTR(最低+(最高-最低)*3/8,2)),Color0095BC;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*5/8)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 5/8↑'+NUMTOSTR(最低+(最高-最低)*5/8,2)),Color0095BC;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*7/8)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 7/8↑'+NUMTOSTR(最低+(最高-最低)*7/8,2)),Color0095BC;
DRAWTEXT(BARPOS=SYSPARAM(2) and K=2,REF((最低+(最高-最低)*3/4)*0.996,BARSLAST(BARSCOUNT(C)=SYSPARAM(2))),'江恩 3/4↑'+NUMTOSTR(最低+(最高-最低)*3/4,2)),Color0095BC;
P:=(C+H+L)/3;
R1:=2*P-L;
S1:=2*P-H;
R2:=P+(R1-S1);
S2:=P-(R1-S1);
SZ1:='压力2:'+NUMTOSTR(R2[SYSPARAM(1)],2)+'\n压力1:'+NUMTOSTR(R1[SYSPARAM(1)],2);
SZ2:='支撑1:'+NUMTOSTR(S1[SYSPARAM(1)],2)+'\n支撑2:'+NUMTOSTR(S2[SYSPARAM(1)],2);
DRAWTEXT(BARSCOUNT(C)=SYSPARAM(1),h*1.02,SZ1),ALIGN2,COLOREEBFFF;
DRAWTEXT(BARSCOUNT(C)=SYSPARAM(1),l*0.98,SZ2),ALIGN2,COLORFF9F93;




来函数检测结果如下:
该公式没有未来函数

解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图