1.三条置换移动平均线【主图】
D3X3:ma(c,3),SHIFT3,COLORCYAN;
D7X5:ma(c,7),SHIFT5,COLORCYAN;
D25X5:ma(c,25),SHIFT5,COLORCYAN;
2.macd
Fast:eMA(close,8.3896)-eMA(close,17.5185),colorred;
Slow:eMA(fast,9.0503),COLORCYAN;
drawicon(cross(fast,slow),fast,5);
PARTLINE(1>0,0);
3.随机指标
RSV:=(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100;
K:SMA(RSV,3,1),colorred;
D:SMA(K,3,1),COLORCYAN;
drawicon(cross(k,d)andk<20,d,7);
4.超买超卖
C-ma(C,7),colorwhite;
5.摆动指标预测器(DOP)【主图】
DMA3X3:ma(c,3),SHIFT3,COLORMAGENTA;
INPUT:N(135,1,250);
v1:=C-ma(C,7);
vv:=v1;
e:=SORT(vv,0,datacount-N,DATACOUNT);
smax:=(vv+vv+vv)/3;
smin:=(vv+vv+vv)/3;
超买价:smax*7/6+ma(c,6),shift1,COLORCYAN;
超卖价:smin*7/6+ma(c,6),shift1,COLORCYAN;
DRAWI CON(high>超买价,high*1.01,7);
DRAWICON(low<超卖价,low*0.99,6);
drawtext(barpos=SYSPARAM(2),sysparam(5),'n明日超买价:'+numtostr(超买价,2)),colorgreen,PXUP75;
drawtext(barpos=SYSPARAM(2),sysparam(5),'nnn明日超卖价:'+numtostr(超卖价,2)),colorgreen,PXUP75;
drawtext(barpos=SYSPARAM(2),sysparam(5),'nnnnn明日DMA3x3:'+numtostr(ref(DMA3X3,2),2)),colorgreen,PXUP75;
6.MACD预测器(DMP)【主图】
//dinapolimacd
bb:=close;
ema08<1>:=bb<1>;
ema17<1>:=bb<1>;
fast<1>:=0;
slow<1>:=0;
fori=2todatacountdo
begin
ema08:=(bb*2+ema08*7.3896)/9.3896;//ema(x:single,n:single)
ema17:=(bb*2+ema17*16.5185)/18.5185;
Fast:=ema08-ema17,colorred;
Slow:=(fast*2+slow*(8.0503))/(10.0503),COLORCYAN;
end;
//dmp
dmp:(18.5185*9.3896*slow+ema17*9.3896*16.5185-ema08*18.5185*7.3896)/18.2578,colorred,shift01;//18.2578=2*(17.5185-8.3896);
DRAWNUMBER(ISLASTBAR,dmp,dmp,2),colored;
7、帝式DSP随机指标【主图】
RS:=(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100;
KSMA:=SMA(RS,3,1);
DSMA:=SMA(KSMA,3,1);
F:=HHV(HIGH,8)-LLV(LOW,8);
DSP:((DSMA*3-KSMA*2)*F/100+LLV(LOW,8)),SHIFT1,linethick1,colorgreen;
PARTLINE(CLOSE>REF(DSP,1),REF(DSP,1)),LINETHICK1,colorFF;
【大智慧系列的帝式指标】
1、XDMA(置换移动平均线)——主图指标:
上唇:REF(SMA(C,3,1),3),COLORGREEN,LINETHICK1;
牙齿:REF(SMA(C,7,1),5),COLORRED,LINETHICK2,CROSSDOT;
下颚:REF(SMA(C,25,1),5),COLORBLUE,LINETHICK2;
或(老帝的原书是下面的这个)
上唇:REF(MA(C,3),3),COLORGREEN,LINETHICK1;
牙齿:=REF(MA(C,7),5),COLORRED,LINETHICK1,CROSSDOT;
下颚:=REF(MA(C,25),5),COLORBLUE,LINETHICK1;
2、XMACD(MACD)——附图指标:
AA:EMA(C,8)-EMA(C,17);
MACD:EMA(AA,9);
3、XMP(MACD指标预测器)——主图指标:
AA:=EMA(C,8);
BB:=EMA(C,17);
CC:=EMA(AA-BB,9);
XMP:9*REF(CC,1)-7*REF(AA,1)+8*REF(BB,1);
4、XKD(修正kd指标)随机指标——附图指标:
RSV:=(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100;
K:SMA(RSV,3,1);
D:SMA(K,3,1);
5、DTO(去趋势摆荡指标)——附图指标:
DTO:C-MA(C,7);
UP:HHV(DTO,60);
DW:LLV(DTO,60);
ZZ:0;
6、DOP(去趋势指标预测器)——主图指标(数据期间60可以改成更适合的数值,老帝原书说的是六个月余约120个交易日):
AA:=C-MA(C,7);
UP:=HHV(AA,60);
DW:=LLV(AA,60);
DOPU:7/6*UP*0.9+REF(MA(C,6),1);
DOPD:7/6*DW*0.9+REF(MA(C,6),1);
【同花顺版本的帝式指标】(通达信系统基本可直接使用)
1、DOP(去趋势指标预测器)(主图)
//设置参数/最小/最大/默认
//n/1/100/7
//m/1/1000/34
//注意上面这部分手工录入
AA:=C-MA(C,n);
UP:=HHV(AA,m);
DW:=LLV(AA,m);
超买价:7/6*UP*0.9+REF(MA(H,6),1),colorred;
超卖价:7/6*DW*0.9+REF(MA(L,6),1),colorgreen;
中间价:ref(ema(c,3),3),Colorffffff;
DRAWICON(HIGH>超买价,HIGH*1.01,"bzt_ggfszx");
DRAWICON(LOW<超卖价,LOW*0.99,"bzt_gglszx");
2、三条置换移动平均线(主图)
D3X3:ref(ma(c,3),3),COLORCYAN;
D7X5:ref(ma(c,7),5),COLORyellow;
D25X5:ref(ma(c,25),5),COLORred;
3、macd
快线:EMA(CLOSE,8.3896)-EMA(CLOSE,17.5185),colorred;
慢线:EMA(快线,9.0503),colorcyan;
DRAWICON(CROSS(快线,慢线),快线,"5");
界:0,Coloreeeeee;
SELECTCROSS(快线,慢线);
4.随机指标
RSV:=(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100;
K:SMA(RSV,3,1),colorred;
D:SMA(K,3,1),COLORCYAN;
DRAWICON(CROSS(k,d)ANDk<=20,d,"bzt_gglszx");
DRAWICON(CROSS(d,k)ANDd>=80,d,"bzt_ggfszx");
SELECTCROSS(k,d);
5.超买超卖
C-ma(C,7),colorwhite;
6.MACD预测器(DMP)【主图】
AA:=EMA(C,8);
BB:=EMA(C,17);
CC:=EMA(AA-BB,9);
XMP:9*REF(CC,1)-7*REF(AA,1)+8*REF(BB,1),coloryellow;