以下是通达信未来函数参考指标源码和截图
通达信未来函数参考指标源码:
(n:20,mm:33)MTR:=EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),N);HD:=HIGH-REF(HIGH,1);LD:=REF(LOW,1)-LOW;DMP:=EXPMEMA(IF(HD 0 HD LD,HD,0),N);DMM:=EXPMEMA(IF(LD 0 LD HD,LD,0),N);PDI:DMP*100/MTR;MDI:DMM*100/MTR;ADX:=EXPMEMA(ABS(MDI-PDI)/(MDI+PDI)*100,MM);ADXR:EXPMEMA(ADX,MM);谷:=TROUGHBARS(2,5,2);
峰:=PEAKBARS(2,5,2);
DRAWTEXT(CROSS(谷,峰),H*1.01,'高')COLORGREEN;
DRAWTEXT(CROSS(峰,谷),L*0.99,'低')COLORRED;
DRAWTEXT(REF(CROSS(谷,峰),1),REF(H,1)*1.01,'出')COLORGREEN;
DRAWTEXT(REF(CROSS(峰,谷),1),REF(L,1)*0.99,'进')COLORRED;
DRAWLINE(CROSS(谷,峰),H,CROSS(峰,谷),L,0)COLORGREEN;
DRAWLINE(CROSS(峰,谷),L,CROSS(谷,峰),H,0)COLORRED;
M5:ma(C,5);
M10:MA(C,10);
M20:MA(C,20);
M60:MA(C,60);
M120:MA(C,120);
M240:MA(C,240);
ZUIS1:=MAX(M5,M10);
ZUIS2:=MAX(ZUIS1,M20);
ZUIS3:=MAX(ZUIS2,M60);
ZUIS4:=MAX(ZUIS3,M120);
ZUIS5:=MAX(ZUIS4,M240);
ZUIX1:=MIN(M5,M10);
ZUIX2:=MIN(ZUIX1,M20);
ZUIX3:=MIN(ZUIX2,M60);
ZUIX4:=MIN(ZUIX3,M120);
ZUIX5:=MIN(ZUIX4,M240);
DRAWTEXT(crOSS(C,ZUIX5),ZUIX5,'建仓'),COLORMAGENTA;
DRAWTEXT(CROSS(ZUIS5,C),ZUIS5,'减仓'),COLORGREEN;
通达信未来函数参考指标截图