交易指导主图指标 (源码)
通达信交易指导主图指标公式股票软件源码如下:
DX:=(C+H+L+O)/4;
短线:(MA(DX,1)+MA(DX,3)+MA(DX,5))/3,COLORFFFFFF;
MTM:=C-REF(C,1);
ZLGJ:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
FB:=MA(DX,17)+ABS(MA(DX,17)-REF(MA(DX,17),1));
FS:=MA(DX,17)+MA(DX,17)-REF(MA(DX,17),1);
搏杀线:IF(MA(DX,17)<FS,FS,MA(DX,17)),LINETHICK2,COLOR000FFF;
IF(FB>FS,搏杀线,DRAWNULL),COLOR00FF00;
DRAWBAND(FS,FB>FS,FB,RGB(0,250,0));
UPPER:= 搏杀线 + 2*STD(CLOSE,20);
买1:=IF(LLV(ZLGJ,2)=LLV(ZLGJ,7) AND COUNT(ZLGJ<0,2) AND CROSS(ZLGJ,MA(ZLGJ,2)),1,0);
卖1:=IF(HHV(ZLGJ,2)=HHV(ZLGJ,7) AND COUNT(ZLGJ>50,2) AND CROSS(MA(ZLGJ,2),ZLGJ),1,0);
STICKLINE(FILTER(买1=1,5),C,O,1,0),COLORFF00FF;
STICKLINE(FILTER(卖1=1,1),C,O,1,0),COLOR00FF00;
RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
BDGD:=HHV(J,2)=HHV(J,8) AND J>80;
注意:=IF(CROSS(REF(J-0.01,1),J) AND REF(BDGD,1),1,0);
STICKLINE(注意 AND 卖1<1,O,CLOSE,1,0),COLORYELLOW,LINETHICK2;
A:=(3*C+L+O+H)/6;
BB:=(20*A+19*REF(A,1)+18*REF(A,2)+17*REF(A,3)+16*REF(A,4)+15*REF(A,5)+14*REF(A,6)
+13*REF(A,7)+12*REF(A,8)+11*REF(A,9)+10*REF(A,10)+9*REF(A,11)+8*REF(A,12)
+7*REF(A,13)+6*REF(A,14)+5*REF(A,15)+4*REF(A,16)+3*REF(A,17)+2*REF(A,18)+
REF(A,20))/210;
生死89线:EMA(BB,89),LINETHICK3,COLORYELLOW;
价涨量缩:DRAWICON(FILTER(REF(V,3)>REF(V,2)*1.1 AND REF(V,2)>=REF(V,1)*1.1
AND REF(V,1)<=V AND L>REF(L,3) AND REF(C,3)>REF(O,3) AND
REF(L,1)>REF(LOW,3),5),L,13);
STICKLINE(搏杀线>生死89线 AND CROSS(短线,搏杀线),L,L*0.99,3,0),COLOR00FF00;
VAR1:=MA((VOL-REF(VOL,1))/REF(VOL,1),5);
VAR2:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;
MY:=VAR2*(1+VAR1);
SHT:= MY;
SHTMA:= MA(SHT,5);
IF(SHTMA>=MY,短线,DRAWNULL),COLOR00FF00;
IF(SHTMA<=MY,短线,DRAWNULL),COLORAA00FF;
{www.gpxiazai.com 股票软件下载网_通达信股票指标公式}
B5线:MA(C,55),POINTDOT,COLORRED;
STICKLINE((CLOSE >B5线),B5线,B5线,3,2),LINETHICK3,COLORRED;
STICKLINE((B5线 > CLOSE),B5线,B5线,3,2),LINETHICK3,COLORGREEN;
牛熊线:(EMA(CLOSE,30)+EMA(CLOSE,72))/2,LINETHICK2,COLORBLUE ;
IF(C>=牛熊线,牛熊线,DRAWNULL),COLORMAGENTA,LINETHICK2.1;
DRAWTEXT(CROSS("MACD.DIF","MACD.DEA"),L,'M');
DRAWTEXT(CROSS("KD.K","KD.D"),L,'J');
DRAWTEXT(CROSS("DMA.DIF","DMA.AMA"),L,'D');
STICKLINE(CROSS("DMA.DIF","DMA.AMA"),O,C,1,0),COLORMAGENTA;
STICKLINE(CROSS("MACD.DIF","MACD.DEA"),O,C,1,0),COLORYELLOW;
{蓝}
STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,3,0),COLORFF7700;
STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,2.2,0),COLORFF9900;
STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,1.5,0),COLORFFBB00;
STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,0.5,0),COLORCYAN;
{彩色K线}
F:=100*(C-REF(C,1))/REF(C,1);
今小昨:=IF(C<REF(O,1) AND F<0,1,0);
P1:=今小昨;
今小前:=IF(C<REF(O,2) AND F<0,1,0);
P2:=今小前;
DRAWTEXT(P1=0 AND REF(P1,1)=1 AND P2=0 AND REF(P2,1)=1,L,'变O'),COLORFF00FF;
STICKLINE(P1=1 AND REF(P1,1)=0 AND P2=1 AND REF(P2,1)=0,OPEN,CLOSE,1.1,0),COLORBLUE;
DRAWTEXT_FIX(1,0.00,0,0,'所属行业:')COLOR0080FF;
DRAWTEXT_FIX(1,0.07,0,0,HYBLOCK)COLOR0080FF;
DRAWTEXT_FIX(1,0.14,0,0,'所属地区:')COLOR00FFFF;
DRAWTEXT_FIX(1,0.21,0,0,DYBLOCK)COLOR00FFFF;
- 上一篇公式:简单实用DMI指标 (源码)
- 下一篇公式:财务特破选股指标 (源码)