网友求助:
源码:
{n:2,100,14}
TYP:=(HIGH+LOW+CLOSE)/3;
CCI:(TYP-MA(TYP,N))/(0.015*AVEDEV(TYP,N));
强势区:100,LINETHICK1,COLORRED;
强弱分水岭:0,LINETHICK1,COLORBLUE;
弱势区:-100,LINETHICK1,COLORGREEN;
DRAWICON(LONGCROSS(CCI,强势区,0.1),CCI,1),COLORRED;
DRAWICON(LONGCROSS(强势区,CCI,0.1),强势区,2),COLORGREEN;
请老师编写出如附图所示,在第一次上穿后5日内cci二次上穿强势区的预警公式
非常感谢英雄起鸟名朋友的帮助,祝你端午节快乐!
解答如下:
TYP:=(HIGH+LOW+CLOSE)/3;
CCI:=(TYP-MA(TYP,14))/(0.015*AVEDEV(TYP,14));
COUNT(CROSS(CCI,100),5)=2 AND CROSS(CCI,100);