通达信黄金分割主图指标 自动画线 自动判断上涨浪下跌浪 自动画前一波上涨浪 源码 附图

MA20:=MA(C,20),COLORMAGENTA,LINETHICK2;
AA:MA(C,20),COLORGREEN,LINETHICK2;
MM:MA(C,20),COLORGREEN,LINETHICK2;
IF(C>AA,MM,DRAWNULL),COLORRED,LINETHICK2;
IF(C<AA,MM,DRAWNULL),COLORGREEN,LINETHICK2;
BTMA20:=(CLOSE>MA20) AND (REF(CLOSE,1)>REF(MA20,1)) AND (REF(CLOSE,2)>REF(MA20,2)) AND (REF(CLOSE,3)>REF(MA20,3));

JXX:=BARSLASTCOUNT(C<MA20);
JXX1:=BACKSET((JXX>=4)*JXX,JXX);
JXS:=BARSLASTCOUNT(C>MA20);
JXS1:=BACKSET((JXS>=4)*JXS,JXS);
KGC:=BARSLASTCOUNT(NOT(JXX1 OR JXS1));
JXL:=BARSLASTCOUNT(REF(JXX1>0,KGC));
JXH:=BARSLASTCOUNT(REF(JXS1>0,KGC));
XWZ:=FILTERX(LLV(L,JXL)=L,JXL);
SWZ:=FILTERX(HHV(H,JXH)=H,JXH);
{DRAWLINE(XWZ,L,SWZ,H,0),COLOR00FFFF;在高低点连斜线}
高:=REF(H,BARSLAST(SWZ));
低:=REF(L,BARSLAST(XWZ));
BB:=BARSLAST(JXL=1);{上次JXL等于1距今天数}
顶点2:=REF(高,BARSLAST(JXL)),COLORGREEN;
低点2:=REF(低,BB),COLORGREEN;{上次等于1对应的低价。或用AA:REF(低,BB);}
H23:=((顶点2-低点2)*0.236+低点2);
H38:=((顶点2-低点2)*0.382+低点2);
H中:=((顶点2-低点2)*0.5+低点2);
H61:=((顶点2-低点2)*0.618+低点2);
H80:=((顶点2-低点2)*0.809+低点2);
H138:=((顶点2-低点2)*1.382+低点2);
H161:=((顶点2-低点2)*1.618+低点2);
H261:=((顶点2-低点2)*2.618+低点2);
顶点A:REFDATE(顶点2,DATE),COLORGREEN,LINETHICK2;
低点A:REFDATE(低点2,DATE),COLORGREEN,LINETHICK2;

B38:REFDATE(H38,DATE),COLORGREEN,DOTLINE;
C50:REFDATE(H中,DATE),COLORGREEN,DOTLINE;
D61:REFDATE(H61,DATE),COLORGREEN,DOTLINE;

DRAWTEXT(ISLASTBAR,顶点A,'1.000'),COLORGREEN;

DRAWTEXT(ISLASTBAR,B38,'0.382'),COLORGREEN;
DRAWTEXT(ISLASTBAR,C50,'0.50'),COLORGREEN;
DRAWTEXT(ISLASTBAR,D61,'0.618'),COLORGREEN;
DRAWTEXT(ISLASTBAR,低点A,'0.000'),COLORGREEN;


STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2.5,0),COLORRED;
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.1,0),COLORCC66FF;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,2.5,0),COLORFF9900;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,0.1,0),COLORFFCC00;



未来函数检测结果如下:
该公式包含未来函数:BACKSET
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式

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

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