在黄色字“金叉5天前最低”出现时写一个选股或预警指标

2017-07-31 11:35:00来源:本站整理浏览:203

 在黄色字“金叉5天前最低”出现时写一个选股或预警指标

{主图}
MA5:MA(C,5),DOTLINE;
MA10:MA(C,10),DOTLINE;
死叉:=BARSLAST(CROSS(MA10,MA5));
金叉:=BARSLAST(CROSS(MA5,MA10));
ZG:=FINDHIGHBARS(H,死叉+1,5,1);
ZD:=FINDLOWBARS(L,金叉+1,5,1);
A:REF(H,BARSLAST(CURRBARSCOUNT=CONST(ZG)+1)),COLORRED;
B:REF(L,BARSLAST(CURRBARSCOUNT=CONST(ZD)+1)),COLORGREEN;
DRAWTEXT(CURRBARSCOUNT=CONST(ZG)+1,H,'死叉5天前最高'),COLORYELLOW,DRAWABOVE;
DRAWTEXT(CURRBARSCOUNT=CONST(ZD)+1,L,' 金叉5天前最低'),COLORYELLOW,DRAWABOVE;
DRAWTEXT(CURRBARSCOUNT=CONST(死叉)+1,MA5,'死叉'),COLORGREEN;
DRAWTEXT(CURRBARSCOUNT=CONST(金叉)+1,MA5,'金叉'),COLORRED;
DRAWICON(CONST(ZG)>CONST(ZD) AND COUNT(C>A,ZG)=1 AND C>A AND C/B<1.2,H,1);

公式网www.gpxiazai.com解答:


MA5:=MA(C,5);
MA10:=MA(C,10);
死叉:=BARSLAST(CROSS(MA10,MA5));
金叉:=BARSLAST(CROSS(MA5,MA10));
ZG:=FINDHIGHBARS(H,死叉+1,5,1);
ZD:=FINDLOWBARS(L,金叉+1,5,1);
A:CURRBARSCOUNT=CONST(ZD)+1;

股票公式栏目导航

精品指标推荐

最新热门

本类随机推荐

相关公式