DIFF1:=EMA(CLOSE,12)-EMA(CLOSE,26);
DEA1:=EMA(DIFF1,9);
MACD1:=200*(DIFF1-DEA1);
DIFF2:=EMA(CLOSE,4)-EMA(CLOSE,8);
DEA2:=EMA(DIFF2,4);
macd2:=200*(DIFF2-DEA2);
DIFF3:=EMA(CLOSE,2)-EMA(CLOSE,4);
DEA3:=EMA(DIFF3,2);
MACD3:=200*(DIFF3-DEA3);
A1:=MACD1>REF(MACD1,1) AND MACD1>0;
A2:=MACD2>REF(MACD2,1) AND MACD2>0;
A3:=MACD3>REF(MACD3,1) AND MACD3>0;
SSS买:A1 AND A2 AND A3;
九毛八公式解读
DIFF1赋值:收盘价的12日指数移动平均-收盘价的26日指数移动平均 DEA1赋值:DIFF1的9日指数移动平均 MACD1赋值:200*(DIFF1-DEA1) DIFF2赋值:收盘价的4日指数移动平均-收盘价的8日指数移动平均 DEA2赋值:DIFF2的4日指数移动平均 MACD2赋值:200*(DIFF2-DEA2) DIFF3赋值:收盘价的2日指数移动平均-收盘价的4日指数移动平均 DEA3赋值:DIFF3的2日指数移动平均 MACD3赋值:200*(DIFF3-DEA3) A1赋值:MACD1>1日前的MACD1 AND MACD1>0 A2赋值:MACD2>1日前的MACD2 AND MACD2>0 A3赋值:MACD3>1日前的MACD3 AND MACD3>0 输出SSS买:A1 AND A2 AND A3