将macd夹心公式中diff上穿dn的选股公式
2020/2/17 18:40:03
公式编写说明:
macd夹心公式源码如下:谢谢!!!{参数自行设置:(12,26,9)}DIFF : EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);DEA : EMA(DIFF,M);MACD : 2*(DIFF-DEA), COLORSTICK;VAR1:=HHV(DEA,53);VAR2:=LLV(DEA,55);VAR3:=DEA-(DIFF-DEA);UP:IF(DIFF>VAR1 AND DEA=VAR1,MAX(LLV(VAR1,10),VAR3),VAR1),COLORbb0000,LINETHICK2;DN:IF(DIFF<VAR2 AND DEA=VAR2,MIN(HHV(VAR2,10),VAR3),VAR2),COLORaa00aa,LINETHICK2;
公式源码回答:
DIFF:=EMA(C,12)-EMA(C,26);
DEA :=EMA(DIFF,9);
MACD:=2*(DIFF-DEA);
VAR1:=HHV(DEA,53);
VAR2:=LLV(DEA,55);
VAR3:=DEA-(DIFF-DEA);
UP:=IF(DIFF>VAR1 AND DEA=VAR1,MAX(LLV(VAR1,10),VAR3),VAR1);
DN:=IF(DIFF<VAR2 AND DEA=VAR2,MIN(HHV(VAR2,10),VAR3),VAR2);
选股:CROSS(DIFF,DN);
投股 票网 www.tou1 8.cn
股市公式下载推荐