您的位置:爱股网 > 查股公式 > 通达信绝色指标源码主图[查股公式]
股票行情消息数据:

通达信绝色指标源码主图[查股公式]

2022/5/29 20:09:27

黄金率在指数运行点位上具有很好的预测性。
2016年一月份的下跌幅度,至今反弹的高点仅仅过了38.2%。以往的历史上,反弹38.2%幅度时往往恢复原来的趋势。
 我上次发黄金分割指标时就预测了大盘在XOP=1.618(3074.86)的3069.05完成了2807.60起涨的反弹。并预测回撤后将有第五浪的最后一波。但回撤深度低了,不符合波浪理论第四浪的的要求。似乎现在的震荡更符合收缩三角形的形态特征。目前,尽管收缩三角形震荡越来越窄了--大家看第一张图--在这个收缩三角形的震荡过程中,无一例外地遵循了黄金率的幅度。
 那么,完成收缩三角形的震荡还需要一段时间,但之后,大盘会怎么走呢?大家看最后的两张图,这是周末时的臆想,所以图上没有今天的那根K线

说了这么多,其实还是要发一个指标的,叫绝色指标,一是因为彩色,令人眼花缭乱的色。二是因为这彩色的K线==用黄金分割来把K线做成了金箍棒:金箍棒是上涨K线;银箍棒是下跌K线;38.2%到61.8%粉色芯是大资金流入;绿色芯是大资金流出;蓝色芯是无大单交易--当然,没有下载L2数据,也会显示蓝色芯。灰色部分是19.1%到80.9%,中间的横线是50%--纯属好玩,意义不大。
 
{阻力支撑}
GJ:=(C+H+L+O)/4;
阻:=L+(GJ-L)+(C-L);
支:=L+(C-GJ);
压力:REF(阻 , 1),NODRAW,COLOR00FF00;
支撑:REF(支 , 1),NODRAW,COLORYELLOW;

{黄金分割}
N:=8;{你随意调整N的参数,看看效果如何:你可以发现更多级别的阻力和支撑点}
高:=IF (HIGH>PEAK(1,N,1),HHV(HIGH,N),PEAK(1,N,1)),COLORGREEN;{最高价}
低:=IF (LOW<TROUGH(2,N,1),LLV(LOW,N),TROUGH(2,N,1)),COLORMAGENTA;{最低价}

F0.191:=(高-低)*0.191+低,DOTLINE,COLORMAGENTA;
F0.382:=(高-低)*0.382+低,DOTLINE,COLORCYAN;
F0.500:=(高-低)*0.500+低,DOTLINE,COLORWHITE;
F0.618:=(高-低)*0.618+低,DOTLINE,COLORCYAN;
F0.809:=(高-低)*0.809+低,DOTLINE,COLORYELLOW;
DRAWBAND(低,RGB(0,0,0),F0.191,RGB(150,0,0));
DRAWBAND(F0.191,RGB(0,0,0),F0.382,RGB(150,0,150));
DRAWBAND(F0.382,RGB(0,0,0),F0.500,RGB(100,100,0));
DRAWBAND(F0.500,RGB(0,0,0),F0.618,RGB(0,100,100));
DRAWBAND(F0.618,RGB(0,0,0),F0.809,RGB(0,0,150));
DRAWBAND(F0.809,RGB(0,0,0),高,RGB(0,100,0));

{黄金分割点位}
波谷↑:=TROUGHBARS(2,N,1);{波谷起涨位}
波峰↓:=PEAKBARS(1,N,1);{波峰起跌位}
ZHSJ:=IF(波峰↓<波谷↑,BACKSET(ISLASTBAR,波峰↓),IF(波谷↑<波峰↓,BACKSET(ISLASTBAR,波谷↑),0));
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),高*1.003,'高')COLORGREEN;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.191*1.002,'  80.9%'),COLORYELLOW;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.382*1.002,'  61.8%'),COLORCYAN;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.500*1.002,'  50.0%'),COLORWHITE;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.618*1.002,'  38.2%'),COLORGREEN;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.809*1.002,'  19.1%'),COLORRED;
DRAWTEXT(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),低*1.002,'低')COLORRED;

DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),高,高)COLORGREEN;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.809,F0.809)COLORMAGENTA;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.618,F0.618)COLORCYAN;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.500,F0.500)COLORWHITE;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.382,F0.382)COLORCYAN;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),F0.191,F0.191)COLORYELLOW;
DRAWNUMBER(波峰↓<波谷↑ AND CROSS(ZHSJ,0.1),低,低)COLORRED;

DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),高*1.003,'高')COLORGREEN;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.191*1.002,'  19.1%'),COLORRED;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.382*1.002,'  38.2%'),COLORGREEN;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.500*1.002,'  50.0%'),COLORWHITE;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.618*1.002,'  61.8%'),COLORCYAN;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.809*1.002,'  80.9%'),COLORYELLOW;
DRAWTEXT(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),低*1.002,'低')COLORRED;

DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),高,高)COLORGREEN;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.809,F0.809)COLORYELLOW;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.618,F0.618)COLORCYAN;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.500,F0.500)COLORWHITE;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.382,F0.382)COLORCYAN;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),F0.191,F0.191)COLORMAGENTA;
DRAWNUMBER(波峰↓>波谷↑ AND CROSS(ZHSJ,0.1),低,低)COLORRED;

{跌K线:艳蓝色}
XG2:=O>=C;
STICKLINE(XG2,L,H,0,0),COLORFF9900;
STICKLINE(XG2,CLOSE,OPEN,3,0),COLORFF5500;
STICKLINE(XG2,CLOSE,OPEN,2.8,0),COLORFF6600;
STICKLINE(XG2,CLOSE,OPEN,2.5,0),COLORFF7700;
STICKLINE(XG2,CLOSE,OPEN,2.2,0),COLORFF8800;
STICKLINE(XG2,CLOSE,OPEN,1.7,0),COLORFF9900;
STICKLINE(XG2,CLOSE,OPEN,1.2,0),COLORFFAA00;
STICKLINE(XG2,CLOSE,OPEN,0.7,0),COLORFFCC00;
STICKLINE(XG2,CLOSE,OPEN,0.2,0),COLORFFFF00;
{涨K线:黄色}
XG1:=C>O;
STICKLINE(XG1,L,H,0,0),COLOR0088EE;
STICKLINE(XG1,CLOSE,OPEN,3,0),COLOR0055AA;
STICKLINE(XG1,CLOSE,OPEN,2.8,0),COLOR0066BB;
STICKLINE(XG1,CLOSE,OPEN,2.5,0),COLOR0077CC;
STICKLINE(XG1,CLOSE,OPEN,2.2,0),COLOR0088DD;
STICKLINE(XG1,CLOSE,OPEN,1.7,0),COLOR0099EE;
STICKLINE(XG1,CLOSE,OPEN,1.2,0),COLOR00AAFF;
STICKLINE(XG1,CLOSE,OPEN,0.7,0),COLOR00CCFF;
STICKLINE(XG1,CLOSE,OPEN,0.2,0),COLOR00FFFF;
实体80.9%:=(MAX(O,C)-MIN(O,C))*0.809+MIN(O,C) ;
实体61.8%:=(MAX(O,C)-MIN(O,C))*0.618+MIN(O,C) ;
实体38.2%:=(MAX(O,C)-MIN(O,C))*0.382+MIN(O,C) ;
实体19.1%:=(MAX(O,C)-MIN(O,C))*0.191+MIN(O,C) ;
实体50.0%:=(O+C)/2,COLORWHITE NODRAW;
STICKLINE(O<>C,实体80.9%,实体19.1%,2,0),COLORGRAY;
STICKLINE(O<>C,实体61.8%,实体38.2%,1,0),COLORBLUE;
STICKLINE(O<>C,实体50.0%,实体50.0%,4,0),COLORYELLOW;

{资金流向}
超B:=L2_AMO(0,2)/10000.0;
大B:=L2_AMO(1,2)/10000.0;
超S:=L2_AMO(0,3)/10000.0;
大S:=L2_AMO(1,3)/10000.0;
超大单:=(超B)-(超S);
大单:=(大B)-(大S);
大资金流向:=超大单+大单 ;
STICKLINE(大资金流向>0,实体61.8%,实体38.2%,1.2,0),COLORBB00BB;
STICKLINE(大资金流向>0,实体61.8%,实体38.2%,0.7,0),COLORDD00DD;
STICKLINE(大资金流向>0,实体61.8%,实体38.2%,0.2,0),COLORFF33FF;
STICKLINE(大资金流向<0,实体61.8%,实体38.2%,1.2,0),COLOR00BB00;
STICKLINE(大资金流向<0,实体61.8%,实体38.2%,0.7,0),COLOR00DD00;
STICKLINE(大资金流向<0,实体61.8%,实体38.2%,0.2,0),COLOR00FF00;

{黄金率目标点位}
TL:=1000000+160526;DRAWTEXT(DATE=TL ,L*0.997,'DA')COLORCYAN;
TH:=1000000+160606;DRAWTEXT(DATE=TH ,H,'DB')COLORCYAN,DRAWABOVE;
TC:=1000000+160624;DRAWTEXT(DATE=TC ,L*0.997,'DC')COLORCYAN;
TO:=1000000+160413;DRAWTEXT(DATE=TO ,H,'DO')COLORCYAN DRAWABOVE;
IF(DATE=TO ,H,DRAWNULL),COLORCYAN,LINETHICK5,CIRCLEDOT;
IF(DATE=TC ,L,DRAWNULL),COLORRED,LINETHICK5,CIRCLEDOT;

AL:=IF(REFDATE(CLOSE,TL)>REFDATE(CLOSE,TH),REFDATE(HIGH,TL),REFDATE(LOW,TL));
BH:=IF(REFDATE(CLOSE,TL)>REFDATE(CLOSE,TH),REFDATE(LOW,TH),REFDATE(HIGH,TH));
CZF:=IF(REFDATE(CLOSE,TL)>REFDATE(CLOSE,TH),REFDATE(HIGH,TC),REFDATE(LOW,TC));
DJB:=IF(REFDATE(CLOSE,TL)>REFDATE(CLOSE,TH),REFDATE(LOW,TO),REFDATE(HIGH,TO));
OP:=BH-AL+CZF;
COP:=0.618*(BH-AL)+CZF;
XOP:=IF((1.618*(BH-AL)+CZF)<0,OP,1.618*(BH-AL)+CZF);
TODAY:=DATE;
STICKLINE(DATE=TC,CZF,XOP,0,-1),COLORYELLOW;
DRAWLINE(DATE=TC,COP,DATE=TODAY,COP,1),DOTLINE,COLORYELLOW;
DRAWLINE(DATE=TC,OP,DATE=TODAY,OP,1),DOTLINE,COLORYELLOW;
DRAWLINE(DATE=TC,XOP,DATE=TODAY,XOP,1),DOTLINE,COLORYELLOW;
DRAWTEXT(DATE=TC,COP*1.002,'COP=0.618'),COLORYELLOW ;
DRAWTEXT(DATE=TC,OP*1.002,'OP=1.000'),COLORYELLOW;
DRAWTEXT(DATE=TC,XOP*1.002,'XOP=1.618'),COLORYELLOW ;
DRAWNUMBER(DATE=TC,COP,COP),COLORYELLOW;
DRAWNUMBER(DATE=TC,OP,OP),COLORYELLOW;
DRAWNUMBER(DATE=TC,XOP,XOP),COLORYELLOW;

DRAWLINE(DATE=TO,DJB,DATE=TL,AL,0) ,COLORYELLOW;
DRAWLINE(DATE=TL,AL,DATE=TH,BH,0) ,COLORYELLOW;
DRAWLINE(DATE=TH,BH,DATE=TC,CZF,0) ,COLORYELLOW;


相关文章列表
天天查股公式列表

股票公式分类

天天查股:股票行情消息 实时DDX在线 资金流向 千股千评 业绩报告 十大股东 最新消息 超赢数据 大小非解禁 停牌复牌 股票分红数据 股票评级报告
广告客服:315126368   843010021
爱股网免费查股,本站内容与数据仅供参考,不构成投资建议,据此操作,风险自担,股市有风险,投资需谨慎。 沪ICP备15043930号-29