日志技术分享
DIFF:=EMA(CLOSE,12)-EMA(CLOSE,27);
DEA:=EMA(DIFF,9);
A1:=BARSLAST(REF(CROSS(DIFF,DEA),1));
底背离:REF(CLOSE,A1+1)CLOSE AND DIFFREF(DIFF,A1+1) AND CROSS(DIFF,DEA);
DIFF:=EMA(CLOSE,5)-EMA(CLOSE,24);
DEA:=EMA(DIFF,5);
A2:=BARSLAST(REF(CROSS(DEA,DIFF),1));
顶背离:=REF(CLOSE,A2+1)CLOSE AND REF(DIFF,A2+1)DIFF AND CROSS(DEA,DIFF);
COUNT(顶背离,5)=1 AND CROSS(DIFF,DEA);
MACD顶底背离副图
DIFF:EMA(CLOSE,12) - EMA(CLOSE,26);
DEA:EMA(DIFF,9);
MACD:2*(DIFF-DEA),COLORSTICK;
A1:=BARSLAST(REF(CROSS(DIFF,DEA),1));
B1:=REF(C,A1+1)C AND REF(DIFF,A1+1)DIFF AND CROSS(DIFF,DEA);
A2:=BARSLAST(REF(CROSS("KDJ.K"(9,3,3),"KDJ.D"(9,3,3)),1));
B2:=REF(C,A2+1)C AND REF("KDJ.K"(9,3,3),A2+1)"KDJ.K"(9,3,3) AND CROSS("KDJ.K"(9,3,3),"KDJ.D"(9,3,3));
A3:=BARSLAST(REF(CROSS("RSI.RSI1"(6,12,24),"RSI.RSI2"(6,12,24)),1));
B3:=REF(C,A3+1)C AND REF("RSI.RSI1"(6,12,24),A3+1)"RSI.RSI1"(6,12,24) AND CROSS("RSI.RSI1"(6,12,24),"RSI.RSI2"(6,12,24));
C1:=BARSLAST(REF(CROSS(DEA,DIFF),1));
D1:=REF(C,C1+1)C AND REF(DIFF,C1+1)DIFF AND CROSS(DEA,DIFF);
C2:=BARSLAST(REF(CROSS("KDJ.D"(9,3,3),"KDJ.K"(9,3,3)),1));
D2:=REF(C,C2+1)C AND REF("KDJ.K"(9,3,3),C2+1)"KDJ.K"(9,3,3) AND CROSS("KDJ.D"(9,3,3),"KDJ.K"(9,3,3));
C3:=BARSLAST(REF(CROSS("RSI.RSI2"(6,12,24),"RSI.RSI1"(6,12,24)),1));
D3:=REF(C,C3+1)C AND REF("RSI.RSI1"(6,12,24),C3+1)"RSI.RSI1"(6,12,24) AND CROSS("RSI.RSI2"(6,12,24),"RSI.RSI1"(6,12,24));
MACD底背:IF(B10,-0.1,0),COLORRED,POINTDOT;
KDJ底背:IF(B20,-0.1,0),COLORFF00FF,POINTDOT;
RSI底背:IF(B30,-0.1,0),COLORYELLOW,POINTDOT;
MACD顶背:IF(D10,0.1,0),COLOR00FF00,POINTDOT;
KDJ顶背:IF(D20,0.1,0),COLORFFCC66,POINTDOT;
RSI顶背:IF(D30,0.1,0),COLORWHITE,POINTDOT;
STICKLINE(B10,-0.1,0,2,0),COLORRED;
STICKLINE(B20,-0.1,0,2,0),COLORFF00FF;
STICKLINE(B30,-0.1,0,2,0),COLORYELLOW;
STICKLINE(D10,0.1,0,2,0),COLOR00FF00;
STICKLINE(D20,0.1,0,2,0),COLORFFCC66;
STICKLINE(D30,0.1,0,2,0),COLORWHITE;
顶背离指当股价K线图上的股票走势一峰比一峰高,股价一直在向上涨,而MACD指标图形上的由红柱构成的图形的走势是一峰比一峰低,即当股价的高点比前一次的高点高、而MACD指标的高点比指标的前一次高点低,这叫顶背离现象。
表示该股价的上涨是外强中干,暗示股价很快就会反转下跌,是比较强烈的卖出信号。
此现象同样适用于外汇交易及贵金属交易(黄金、白银)。
注意事项:
1,各种技术指标有效性并不相同,进行技术指标分析时,相对而言,用RSI与KDJ的背离来研判行情的转向成功率较高。
2,指标背离一般出现在强势中比较可靠,就是价格在高位时,通常只需出现一次背离的形态,即可确认反转形态,而价格在低位时,一般要反复出现几次背离才可确认反转形态。
3,钝化后背离较为准确,若完全根据背离特征进行操作的话,常会带来较大的失误,这种情况特别容易出现在当价格出现暴跌或暴涨的走势时,KDJ指标很可能呈高位或低位钝化后,该股价仍然出现上涨或下跌,实际上,这时候一旦出现背离特征有效性很高,特别时KDJ指标结合RSI指标一起判断股价走向,KDJ在判断底部与顶部过程中,具有较强的指向作用。
{顶底背离极品}
OBV:SUM(IF(CLOSEREF(CLOSE,1),VOL,IF(CLOSEREF(CLOSE,1),-VOL,0)),0),LINETHICK2,COLORGREEN;
B1:=REF(OBV,1);
B2:=REF(OBV,2);
B3:=REF(OBV,3);
B4:=REF(OBV,4);
CMAX:=MAX(MAX(MAX(OBV,B1),B2),B3);
CMIN:=MIN(MIN(MIN(OBV,B1),B2),B3);
持股:=STICKLINE(OBV=CMAX AND (B1=B2 OR B1=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND OBV=B2 OR
B2=CMAX AND B3=CMIN AND OBV=B1 OR B3=CMAX AND OBV=B1 AND OBV=B2,B1,OBV,3,0),COLORMAGENTA;
变盘:STICKLINE(OBV=CMAX AND B1=CMIN,B2,OBV,1,0),COLORWHITE;
DRAWTEXT(变盘,OBV,'变盘'),COLORWHITE;
下跌:=STICKLINE(OBV=CMIN AND (B1B2 OR B1B3) OR B1=CMIN AND (B2=CMAX OR B3=CMAX) AND OBVB2 OR
B2=CMIN AND B3=CMAX AND OBVB1 OR B3=CMIN AND OBVB1 AND OBVB2,B1,OBV,8,1),COLOR00FF00;
STICKLINE(B1=CMAX AND OBV=CMIN,B2,OBV,3,0),COLOR009900 ;
买入:STICKLINE(B1=CMIN AND OBV=B2 OR (B2=CMIN AND B1=B3 OR
B3=CMIN AND B1=B2) AND B2B4 AND OBV=B1,B1,B2,1,0),COLORRED;
DRAWTEXT(买入,OBV,'买入'),COLORRED;
抛售:STICKLINE(B1=CMAX AND OBVB2 OR (B2=CMAX AND B1B3 OR
B3=CMAX AND B1B2) AND B2=B4 AND OBVB1,B1,B2,1,0),COLORCYAN;
DRAWTEXT(抛售,OBV,'抛售'),COLORCYAN;
V1:HHV(OBV,0);
V3:=HHV(OBV,5);
IF(OBV=V3,OBV,DRAWNULL),COLORYELLOW,LINETHICK3;
IF(OBV=V1,OBV,DRAWNULL),COLORRED,LINETHICK3;
MA(OBV,7),COLORWHITE;
MA(OBV,21),COLORLIBLUE;
{DRAWTEXT(((((COUNT((CLOSE REF(CLOSE,1)),30) 18) AND (COUNT((CLOSE REF(CLOSE,1)),3) = 3)) AND ((COUNT((OBV REF(OBV,1)),30) 18) AND (COUNT((OBV REF(OBV,1)),3) = 3))) AND ((COUNT((VOL REF(VOL,1)),30) 3) AND ((VOL / CAPITAL) = (10 / 100)))),OBV,'买盘较强');
DRAWTEXT(((((COUNT((CLOSE REF(CLOSE,1)),30) 18) AND (COUNT((CLOSE REF(CLOSE,1)),3) = 3)) AND ((COUNT((OBV REF(OBV,1)),30) 18) AND (COUNT((OBV REF(OBV,1)),3) = 3))) AND ((COUNT((VOL REF(VOL,1)),30) 3) AND ((VOL / CAPITAL) = (10 / 100)))),OBV,'买盘逐渐加强');}
DRAWTEXT((((COUNT((CLOSE REF(CLOSE,1)),30) 18) AND (COUNT((CLOSE REF(CLOSE,1)),3) = 3)) AND ((COUNT((OBV REF(OBV,1)),30) 18) OR (COUNT((OBV REF(OBV,1)),3) = 3))),OBV,'买盘无力');
DRAWTEXT((CROSS(OBV,0) AND (COUNT((REF(OBV,1) 0),3) = 3)),OBV,'由负转正买入');
DRAWTEXT((CROSS(0,OBV) AND (COUNT((REF(OBV,1) 0),3) = 3)),OBV,'由正转负卖出。');
DRAWTEXT(((HHV(HIGH,20) = HIGH) AND NOT((HHV(OBV,20) = OBV))),OBV,'顶背离卖'),COLORGREEN;
DRAWTEXT(((LLV(LOW,20) = LOW) AND NOT((LLV(OBV,20) = OBV))),OBV,'底背离买'),COLORRED;
DRAWTEXT((((ABS((OBV - REF(OBV,1))) / ABS(MA(OBV,5))) 0.07) AND (OBV REF(OBV,1))),OBV,'异常');
异常选股:
OBV:=SUM(IF(CLOSEREF(CLOSE,1),VOL,IF(CLOSEREF(CLOSE,1),-VOL,0)),0);
异常:(((ABS((OBV - REF(OBV,1))) / ABS(MA(OBV,5))) 0.07) AND (OBV REF(OBV,1)));
底背离选股:
OBV:=SUM(IF(CLOSEREF(CLOSE,1),VOL,IF(CLOSEREF(CLOSE,1),-VOL,0)),0),LINETHICK2,COLORGREEN;
DRAWTEXT(((LLV(LOW,20) = LOW) AND NOT((LLV(OBV,20) = OBV))),OBV,'底背离买');
N:=( 2 ,120, 14);N1:=( 2, 250 ,36);G:=( 1, 60, 15);Z:=( 1, 100, 5);
变动速率:MA(100*(CLOSE-REF(CLOSE,12))/REF(CLOSE,12),6)*Z;
DD1:=REF(变动速率,1);P:=(HIGH+LOW+CLOSE)/3;
CCI1:(P-MA(P,N))*1000/(G*AVEDEV(P,N)),COLORCYAN;
CCI2:=(P-MA(P,N1))*1000/(G*AVEDEV(P,N1));
B1:=BARSLAST(CCI1=LLV(CCI1,60));
DD:=CREF(C,B1) AND CCI1REF(CCI1,B1);
EE:=CREF(C,B1) AND CCI2REF(CCI2,B1);
底背离:IF(DD,-100,0),LINETHICK2,COLORRED;
顶背离:IF(EE,100,0),LINETHICK2,COLORGREEN;
机会难得:IF(CROSS(CCI1,CCI2)
AND REF(CCI1,1)=LLV(CCI1,60),100,0),LINETHICK2,COLORYELLOW;
机会谁得:IF(CROSS(CCI2,CCI1)
AND REF(CCI1,1)=HHV(CCI1,60),100,0),LINETHICK2,COLORWHITE;
{个人看法,仅供参考。}
网站首页:最新期货开户网
期货开户微信:527 209 157
本文链接:http://jienve.com/post/34431.html
Copyright 2010-2024 最新期货开户网 网站地图 微信:527 209 157 湘ICP备18014167号