将KDJ和MACD组合成一个选股公式
更多金钻指标股票技术讨论QQ群:966329692 技术讨论QQ群:220302856 技术讨论QQ群:39652085 如群满可换一个

编写要求:

老师您好: 请老师讲下面的两个公式组合到一起,在KDJ和MACD同一天金叉时,编写一个选股公式,并在同时金叉处做个标记。谢谢!源码如下:DIF1:=EMA(CLOSE,7) - EMA(CLOSE,13);DEA1:=EMA(DIF1,3);MACD1:=2*(DIF1-DEA1),STICK;MACD2:=EMA(MACD1,3);STICKLINE(MACD1>MACD2 AND MACD1>0,0,MACD1,1,0),COLORRED;STICKLINE(MACD1>MACD2 AND MACD1<0,0,MACD1,1,0),COLORGREEN;STICKLINE(MACD1=0 OR MACD1<=0,0,0,50,1),COLORWHITE;DIF:DIF1,COLOR33FF33;DEA:DEA1,COLORYELLOW;MACD:MACD1,NODRAW,COLORMAGENTA;强:IF(DIF1>=DEA1,DIF1,DRAWNULL),COLORRED,LINETHICK2;RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;K:SMA(RSV,M1,1);D:SMA(K,M2,1);J:3*K-2*D;

解答:

 

 
DIF1:=EMA(CLOSE,7) - EMA(CLOSE,13);
DEA1:=EMA(DIF1,3);
MACD1:=2*(DIF1-DEA1),STICK;
MACD2:=EMA(MACD1,3);
STICKLINE(MACD1>MACD2 AND MACD1>0,0,MACD1,1,0),COLORRED;
STICKLINE(MACD1>MACD2 AND MACD1<0,0,MACD1,1,0),COLORGREEN;
STICKLINE(MACD1<MACD2,0,MACD1,1,0),COLORCBCBC0;
STICKLINE(MACD1>=0 OR MACD1<=0,0,0,50,1),COLORWHITE;
DIF:DIF1,COLOR33FF33;
DEA:DEA1,COLORYELLOW;
MACD:MACD1,NODRAW,COLORMAGENTA;
强:IF(DIF1>=DEA1,DIF1,DRAWNULL),COLORRED,LINETHICK2;
金叉1:=CROSS(DIF1,DEA1);
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9));
K:SMA(RSV,3,1);
D:SMA(K,3,1);
J:3*K-2*D;
金叉2:=CROSS(J,K);
DRAWICON(金叉1 AND 金叉2,J,17);
 

选股票看什么指标最好 >股票指标网