角度线+MACD套装

盘感

2015-03-22

关注

看图要点:

    股价的内在力量往往通过速度和角度表现出来:时间短、角度陡、说明攻击力充足,而能长期保持大角度上升的个股更是强中之强;对角线(黄线)可以看做是主趋势线;45度线(绿线)可以看做是强弱分界线;四条虚线分别是50、55、60、65度线、注意对角线和K线与它们的关系、越高则越强势;起点(N),可根据自己的需要进行调整、例如改成60、90、125、250等。

http://blog.sina.com.cn/s/blog_7d80474c01017mm5.html

副图

MACD:"MACD.MACD",NODRAW;
W1:STICKLINE(MACD>0,MACD,0,3,1),COLORRED;
W2:STICKLINE(MACD<0,MACD,0,3,1),COLORCYAN;
VA1:=HHVBARS(MACD,BARSLAST(MACD<0)+1);
VA2:=CROSS(BACKSET(CROSS(0,MACD),REF(VA1,1)+2),0.5);
QG:=CROSS(BACKSET(CROSS(0,MACD) OR (ISLASTBAR AND MACD>0),REF(VA1,1)+2),0.5);
前高:DRAWLINE(VA2,MACD,REF(VA2,1),REF(MACD,1),1),COLORMAGENTA;
VA3:=LLVBARS(MACD,BARSLAST(MACD>0)+1);
VA4:=CROSS(BACKSET(CROSS(MACD,0),REF(VA3,1)+2),0.5);
BD:=BARSLAST(FILTERX(CROSS(0,MACD),BARSCOUNT(C)));
前低:DRAWLINE(VA4,MACD,REF(VA4,1),REF(MACD,1),1);
BDTJ:=IF(MACD<0,FILTERX(MACD=LLV(MACD,BARSLAST(MACD>0)),
BARSCOUNT(C)),DRAWNULL);
TSBDTJ:=BARSLAST(BDTJ);
BDZH:=FILTERX(MACD<CONST(LLV(MACD,BD+1)),BARSCOUNT(C));
BDTS:=BARSLAST(BDZH);
本低:IF(BD+1>=1,CONST(LLV(MACD,BD+1)),DRAWNULL);
BDCL:=CROSS(COUNT(CROSS(MACD>本低/2 AND MACD<0,0.5),TSBDTJ)=1,0.5) AND TSBDTJ>=0;
终点:=IF(ISLASTBAR AND MACD>0 AND MACD=HHV(MACD,BARSLAST(MACD<0)),1,
IF(FILTERX(QG,BARSCOUNT(C)),2,DRAWNULL));
UU:=(终点=1 OR 终点=2) AND MACD>0;
ZZ:=FILTERX(UU,BARSCOUNT(C));
本高:DRAWLINE(ZZ,MACD,REF(ZZ,1),REF(MACD,1),1),COLORWHITE;
横线:=CONST(REF(MACD,BARSLAST(ZZ)));
WW:=MACD>横线;
起始点:=FILTERX(REFX(BARSLAST(WW),1)=1,BARSCOUNT(C));
天数:BARSLAST(起始点),COLORYELLOW,NODRAW;
上横线:DRAWLINE(起始点,横线,ZZ,横线,0),COLORGREEN,DOTLINE;
下横线:DRAWLINE(BDZH,CONST(LLV(MACD,BD+1)),BDTJ=1,MACD,0),COLOR8080FF,DOTLINE;
DRAWNUMBER(BDTJ,CONST(LLV(MACD,BD+1))*0.9,BDTS);
DRAWNUMBER(ZZ,上横线*1.1,天数);
TJ:=IF(起始点,BARSNEXT(ZZ),DRAWNULL);
红柱数量:IF(天数>0 AND 天数<=REF(TJ,天数),SUM(MACD>0,天数),DRAWNULL),COLORWHITE,NODRAW;
横线起始价:REF(C,天数),NODRAW;
空间评估:(横线起始价-C)/C*100,NODRAW;
TT:=BARSLAST(ZZ);
WQG:=CROSS(COUNT(CROSS(MACD<本高/2 AND MACD>0,0.5),ZZ)=1,0.5) AND ZZ>=0;
STICKLINE(MACD>前高 AND 本高>前高 AND BARSLAST(CROSS(MACD<本高/2,0.5))>0 AND
MACD>(前高+本高)/2,MACD,前高,1,0),COLORYELLOW;

前高本高二分位:IF(MACD>0 AND 本高!=前高,DRAWLINE(WQG,(前高+本高)/2,REF(WQG,1),REF((前高+本高)/2,1),1)
,DRAWNULL),COLORC0C000,DOTLINE;
AA:=STRCAT(STRCAT(STRCAT('〖','上升空间'),'〗'),CON2STR(IF(空间评估,空间评估,
DRAWNULL),2));

DRAWTEXT(WQG,MACD*1.1,'本高成立'),COLORWHITE;
DRAWTEXT(BDCL,MACD*1.1,'本低成立'),COLORWHITE;
STICKLINE(MACD>前高,MACD,前高,1,0),COLORYELLOW;
STICKLINE(WQG,MACD,0,1,0),COLORGREEN;
STICKLINE(MACD<0 AND MACD<前低 AND 前低<0,MACD,前低,1,0),COLORBLUE;
B1:=IF(CROSS(MACD<0,0.5),BARSNEXT(BDTJ),DRAWNULL);
TSB1:=BARSLAST(MACD>0)-1;
STICKLINE(BARSLAST(BDCL)>=0 AND MACD<前低 AND MACD<0,MACD,前低,1,0),COLORGREEN;
STICKLINE(BDCL,MACD,0,1,0),COLORWHITE;
STICKLINE(MACD>前高 AND 本高>前高 AND BARSLAST(WQG)>0,
MACD,前高,1,0),COLORRED;
DRAWTEXT(VA2 AND VA2!=UU,(MACD/10)*9,'前');
DRAWTEXT(VA2 AND VA2!=UU,MACD/10,'高');
DRAWTEXT(ZZ,(MACD/10)*9,'本'),COLORWHITE;
DRAWTEXT(ZZ,MACD/10,'高'),COLORWHITE;
DRAWTEXT(BDTJ,(MACD/10)*9,'低'),COLORRED;
DRAWTEXT(BDTJ,MACD/10,'本'),COLORRED;
IF(BARSLAST(BDCL)>=0,本低/2,DRAWNULL),COLORRED,DOTLINE;

DRAWTEXT_FIX(1,0.05,0.04,0,'【黑马拉升由两个阶段构成:同步上涨阶段(黄芯柱)
和惯性上涨阶段(背离阶段、红芯柱)】'),COLORFFFF00;

公式名称:角度线

公式位置:主图

公式优化:标杆2018

公式代码:

N:=30;

TS:=BARSLAST(L=LLV(L,N));

开始信号:=FILTERX(TS=0,BARSSINCE(C));

开始天数:=BARSLAST(开始信号);

天数横线:=CONST(开始天数);

低点:DRAWLINE(L=LLV(L,N),L,ISLASTBAR,REF(L,TS),1),COLORGRAY;

高点:DRAWLINE(L=LLV(L,N),CONST(HHV(H,天数横线)),ISLASTBAR,REF(CONST(HHV(H,天数横线)),

TS),1),COLORGRAY;

STICKLINE(开始信号,L,CONST(HHV(H,天数横线)),0,0),COLORGRAY;

STICKLINE(ISLASTBAR,低点,高点,0,0),COLORGRAY;

DRAWKLINE(HIGH,OPEN,LOW,CLOSE);

C2:=REF(C,1),NODRAW;

涨停:=REF(C,1)*1.1-C<0.01 AND H=C,NODRAW;

STICKLINE(涨停,OPEN,CLOSE,1,0),COLORRED;

STICKLINE(涨停,H,L,0,0),COLORRED;

跌停:=IF((C2-C)*100/C2>=(10-0.01*100/C2) AND L=C,1,0),NODRAW;

STICKLINE(跌停,OPEN,CLOSE,1,0),COLORGREEN;

STICKLINE(跌停,H,L,0,1),COLORGREEN;

差:=(高点-低点)/天数横线;

收盘差:=CONST(C)-低点;

对角差:=高点-低点;

对角角度:ATAN((对角差/(对角差*((天数横线-1)/天数横线))-1)*100)*57.3,COLORFF00FF,NODRAW;

差60度:=(高点-低点)*60/对角角度;

差45度:=(高点-低点)*45/对角角度;

差55度:=(高点-低点)*55/对角角度;

差50度:=(高点-低点)*50/对角角度;

差65度:=(高点-低点)*65/对角角度;

角度65:=IF(TS>=0 AND 低点+(差65度/天数横线)*TS<=高点,低点+(差65度/天数横线)*TS,DRAWNULL),COLORLIBLUE,DOTLINE;

角度50:IF(TS>=0 AND 低点+(差50度/天数横线)*TS<=高点,低点+(差50度/天数横线)*TS,DRAWNULL),COLORLIBLUE,DOTLINE;

角度55:IF(TS>=0 AND 低点+(差55度/天数横线)*TS<=高点,低点+(差55度/天数横线)*TS,DRAWNULL),COLORLIBLUE,DOTLINE;

对角线:IF(TS>=0 AND 低点+差*TS<=高点,低点+差*TS,DRAWNULL),COLORYELLOW,LINETHICK2;

{DRAWBAND(对角线,RGB(255,0,255),对角线,RGB(255,0,255)),LINETHICK2;}

角度60:IF(TS>=0 AND 低点+(差60度/天数横线)*TS<=高点,低点+(差60度/天数横线)*TS,DRAWNULL),COLORLIBLUE,DOTLINE;

角度45:IF(TS>=0 AND 低点+(差45度/天数横线)*TS<=高点,低点+(差45度/天数横线)*TS,DRAWNULL),COLORGREEN;

收盘角度:(收盘差*对角角度)/对角差,NODRAW;

收盘线:=IF(TS>=0 AND 低点+(收盘差/天数横线)*TS<=高点,低点+(收盘差/天数横线)*TS,DRAWNULL);

{DRAWBAND(收盘线,RGB(192,192,192),收盘线,RGB(192,192,192)),DOTLINE,COLORC0C0C0;};

自己补充小箭头选股指标

M1:=MA(MA(C,1),5);
M2:=MA(MA(C,3),5);
SM:=MA(MA(C,16),20);
XG:DRAWICON((C>M1 AND (C>M2) AND (C<SM) AND (M1>M2) 
AND SM<REF(SM,1) AND M1<SM AND M2<SM),M2,1);

(0)

相关推荐