把这个奔牛指标做出条件预警
-
相关简介:编写要求: www.guhai.com.cn 股海网解答: 网友求助: 请老师在20以下S上穿奔牛做出条件预警,多谢!!! 源码如下: VAR2:=(CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100; VAR3:=SMA(SMA(VAR2,3,1),3,1)/28.57; VAR4:=EMA(VAR3,5); VAR5:=3*VAR3-2*VAR4; AA:=CROSS(VAR5,VAR3) AND VAR32.1 AND CO; VAR6:=
-
文章来源:股海网作者:股海网发布时间:2016-04-12浏览次数:
编写要求:
www.guhai.com.cn股海网解答:
网友求助:
源码如下:
VAR2:=(CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100;
VAR3:=SMA(SMA(VAR2,3,1),3,1)/28.57;
VAR4:=EMA(VAR3,5);
VAR5:=3*VAR3-2*VAR4;
AA:=CROSS(VAR5,VAR3) AND VAR3<2.1 AND C>O;
VAR6:=(2*CLOSE+HIGH+LOW)/4;
VAR7:=LLV(LOW,13);
VAR8:=HHV(HIGH,13);
VAR9:=EMA((VAR6-VAR7)/(VAR8-VAR7)*100,13);
VARA:=EMA(0.667*REF(VAR9,1)+0.333*VAR9,2);
S:VAR9,COLORRED,POINTDOT;
STICKLINE(VAR9>VARA,VAR9,VARA,2.6,1),COLOR77AAFF;
STICKLINE(VAR9>VARA,VAR9,VARA,2.6,0),COLOR77AAFF;
STICKLINE(VAR9<=VARA,VAR9,VARA,2.6,1),COLOR00FF00 ;
STICKLINE(VAR9<=VARA,VAR9,VARA,2.6,0),COLOR00FF00 ;
DRAWTEXT(AA,12,'牛'),COLORYELLOW;
A1:10,COLORWHITE;
A2:20,COLORRED;
A3:50,POINTDOT,COLORYELLOW;
A4:70,POINTDOT;
A5:80,COLORRED;
奔牛: EMA(0.382*REF(VAR9,2)+0.618*VAR9,6);
IF(奔牛>REF(奔牛,1),奔牛,DRAWNULL),COLORRED,LINETHICK2;
IF(奔牛<REF(奔牛,1),奔牛,DRAWNULL),COLORYELLOW,LINETHICK2;
持仓:IF(VAR9>VARA,50,DRAWNULL),COLORFF00FF;
空仓:IF(VAR9<VARA,50,DRAWNULL),COLORFFFF00;
VAR7:=LLV(LOW,13);
VAR8:=HHV(HIGH,13);
VAR9:=EMA((VAR6-VAR7)/(VAR8-VAR7)*100,13);
S:=VAR9;
奔牛:=EMA(0.382*REF(VAR9,2)+0.618*VAR9,6);
S<20 AND CROSS(S,奔牛);