以下是通达信MACD脉冲幅图公式 源码

MACD脉冲幅图公式 源码

TDXSTEP100:0.4,COLORBLUE;

DIF:EMA(CLOSE,12)-EMA(CLOSE,26);

DEA:EMA(DIF,9);

MACD:(DIF-DEA)*2,COLORSTICK;

A1:=1.5*(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)+EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)-REF(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)+EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14),1))/(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)+EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14));

脉冲:MA(A1*(MA(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14),1)/(EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)))*(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)-EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14))/MA(EXPMEMA(IF(REF(LOW,1)-LOW>0 AND REF(LOW,1)-LOW>HIGH-REF(HIGH,1),REF(LOW,1)-LOW,0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14)-EXPMEMA(IF(HIGH-REF(HIGH,1)>0 AND HIGH-REF(HIGH,1)>REF(LOW,1)-LOW,HIGH-REF(HIGH,1),0),14)*100/EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),14),1),1)*0.5;

MACD脉冲幅图公式 源码

声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。