长短周期复合MACD,既保持长周期的大趋势,又能及时反映短周期的波动。以下三组式子可根据各人经验习惯观摩试验。
C/C++ Code复制内容到剪贴板
- {SY_MACD SHORT,2~200,12;LONG,2~200,26;MID,2~200,9};
- {XD_DIF:(EMA(CLOSE,SHORT/2)-0.7*EMA(CLOSE,SHORT)-0.3*EMA(CLOSE,LONG))/
- (MA(CLOSE,SHORT)+0.1)*100;
- XD_DEA:EMA(XD_DIF,MID);
- XD_MACD:(XD_DIF-XD_DEA)*2,COLORSTICK;}
-
- {对比
- XD_DIFF:(EMA(CLOSE,SHORT)-EMA(CLOSE,LONG))/(MA(CLOSE,SHORT)+0.1);
- XD_DEAA:EMA(XD_DIFF,MID);
- XD_MACD:(XD_DIFF-XD_DEAA)*2,COLORSTICK;};
-
- DIF:(EMA(CLOSE,SHORT/2)-0.7*EMA(CLOSE,SHORT)-0.3*EMA(CLOSE,LONG));
- DEA:EMA(DIF,MID);
- CD_MACD:(DIF-DEA)*2,COLORSTICK;