柱状线,由红变绿(正变负),卖出信号参考;由绿变红,买入信号参考。
DIFF = EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);
DEA = EMA(DIFF,M);
MACD = 2*(DIFF-DEA);
Zero = 0;
RSV=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;
a=SMA(RSV,M1,1);
b=SMA(a,M2,1);
e=3*a-2*b;
IF(a 0) a=0;
IF(a 100) a=100;
IF(b 0) b=0;
IF(b 100) b=100;
IF(e 0) e=0;
IF(e 100) e=100;
K=a;
D=b;
J=e;
LC = REF(CLOSE,1);
RSI$1=SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100;
RSI$2=SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100;
RSI$3=SMA(MAX(CLOSE-LC,0),N3,1)/SMA(ABS(CLOSE-LC),N3,1)*100;
乖离率=MACD+(j-d)/15+(RSI$1-RSI$3)/10;
参考=MACD*1.5+(j-d)/12+(RSI$1-RSI$3)/8;
相差=2*(参考-乖离率);
其他:MA(相差,5);