zjtz288 发表于 2016-2-20 20:55

很好的抄底指标(源码

此指标多年来我一直使用,这次奉献给大家**** Hidden Message *****
{原文链接:http://www.guhai.com.cn/html/GS/tong-da-xin/82622.html}

怀无常 发表于 2016-2-21 12:03

{撑压互换主图指标}
ZZZT:=IF((C-REF(C,1))*100/REF(C,1)>=(10-0.009*100/REF(C,1)),2,0) AND C=H;
DZZT:=IF((REF(C,1)-C)*100/REF(C,1)>=(10-0.009*100/REF(C,1)),2,0) AND C=L;
SP:=IF((C<100),C,(C/100));
DS:=INTPART(((4*(LOG(SP)/LOG(2)))+1));
HHH1:=((DS-1)/4);
长支撑:IF((C>100),(POW(2,HHH1)*100),POW(2,HHH1)),POINTDOT,LINETHICK4,COLORBROWN;
DRAWTEXT(ISLASTBAR,长支撑,'长支撑'),COLOR0000EE;
长压力:IF((C>100),(POW(2,(HHH1+(1/4)))*100),POW(2,(HHH1+(1/4)))),
POINTDOT,LINETHICK4,COLOR009900;
DRAWTEXT(ISLASTBAR,长压力,'长压力'),COLOREE0000;
{巨量平台}
ZZT:=REF(C,1)*1.1-C<0.01 AND H=C;
{STICKLINE( ZZT,C,O,2,0),COLORYELLOW;}
{走强线:EMA(COST(99),181),COLORYELLOW,LINETHICK2;}
巨量平台:REF(H,BARSLAST(V=HHV(VOL,120))),COLORRED,LINETHICK2;
XG:= NOT(REF(巨量平台,1)=巨量平台) AND ZZT;
DRAWTEXT(XG,L,'量爆'),COLORCYAN;
主升:=CROSS(C,巨量平台);
DRAWTEXT(主升,L,'↖主升'),COLORYELLOW;
DRAWTEXT(主升 AND ZZT,L,'↖超级主升'),COLORRED;
{高点低点画线}
G:=MA(C,5);
D:=MA(C,10);
HH:=REF(H,5)=HHV(H,11);
LL:=REF(L,5)=LLV(L,11);
FG01:=BACKSET(HH,6)>BACKSET(HH,5);
FD01:=BACKSET(LL,6)>BACKSET(LL,5);
FG02:=IF(BARSLAST(FG01)=BARSLAST(FD01) AND G>D,FG01,
IF(BARSLAST(FD01)>BARSLAST(FG01),FG01,0));
FD02:=IF(BARSLAST(FG01)=BARSLAST(FD01) AND D>G,FD01,
IF(BARSLAST(FG01)>BARSLAST(FD01),FD01,0));
FG0:=FG02 AND H=HHV(H,BARSLAST(FD02));
FD0:=FD02 AND L=LLV(L,BARSLAST(FG02));
GP:=IF(FG0,H,DRAWNULL),CIRCLEDOT,COLORCYAN;
DP:=IF(FD0,L,DRAWNULL),CIRCLEDOT,COLORCYAN;
GQ:=L>REF(H,1) AND DAY!=REF(DAY,1);
DQ:=H<REF(L,1) AND DAY!=REF(DAY,1);
GQL:=REF(L,BARSLAST(GQ));
DQH:=REF(H,BARSLAST(DQ));
FGH:=REF(H,BARSLAST(FG0));
FGL:=REF(L,BARSLAST(FG0));
FGH1:=REF(H,BARSLAST(FG0)+1);
FGL1:=REF(L,BARSLAST(FG0)+1);
FGH2:=REF(H,BARSLAST(FG0)+2);
FGL2:=REF(L,BARSLAST(FG0)+2);
FDH:=REF(H,BARSLAST(FD0));
FDL:=REF(L,BARSLAST(FD0));
FDH1:=REF(H,BARSLAST(FD0)+1);
FDL1:=REF(L,BARSLAST(FD0)+1);
FDH2:=REF(H,BARSLAST(FD0)+2);
FDL2:=REF(L,BARSLAST(FD0)+2);
FGZH:=IF(FGL<=FGL1,FGH2,FGH1);
FGZL:=IF(FGH1<FGL,FGL,IF(FGL<=FGL1,FGL2,FGL1));
FDZH:=IF(FDL1>FDH,FDH,IF(FDH>=FDH1,FDH2,FDH1));
FDZL:=IF(FDH>=FDH1,FDL2,FDL1);
FG1:=FGH>FDZH AND FG0;
FD1:=FDL<FGZL AND FD0;
FG:=FG1 AND FGH>FDH AND FGL>FDL AND FGL1>FDL;
FD:=FD1 AND FDL<FGL AND FDH<FGH AND FDH1<FGH;
BH0:=(H<=REF(H,1) AND L>=REF(L,1)) OR (H>=REF(H,1) AND L<=REF(L,1));
BHG:=COUNT(BH0,BARSLAST(FD0));
BHD:=COUNT(BH0,BARSLAST(FG0));
BGQ:=COUNT(GQ,BARSLAST(FD0));
BDQ:=COUNT(DQ,BARSLAST(FG0));
BK0:=IF(BHG>0,BHG+2,IF(BHD,BHD+2,3));
BK:=IF(BGQ,BK0-BGQ,IF(BDQ,BK0-BDQ,BK0));
G1X:=(FG AND BARSLAST(FD)>BK);
D1X:=(FD AND BARSLAST(FG)>BK);
G1:=(FG0 AND REF(H,BARSLAST(FG0))>=REF(H,BARSLAST(G1X)) AND BARSLAST(D1X)>BARSLAST(G1X))
OR (FG1 AND COUNT(GQ,BARSLAST(FD1))>0 AND REF(H,BARSLAST(FG1))>REF(H,BARSLAST(G1X)));
D1:=(FD0 AND REF(L,BARSLAST(FD0))<=REF(L,BARSLAST(D1X)) AND BARSLAST(G1X)>BARSLAST(D1X))
OR (FD1 AND COUNT(DQ,BARSLAST(FG1))>0 AND REF(L,BARSLAST(FD1))<REF(H,BARSLAST(D1X)));
G1H:=IF(BARSLAST(D1)>BARSLAST(G1),REF(H,BARSLAST(G1)),REF(H,BARSLAST(D1))),;
D1L:=IF(BARSLAST(G1)>BARSLAST(D1),REF(L,BARSLAST(D1)),REF(L,BARSLAST(G1)));
G2:=G1 AND H=HHV(G1H,BARSLAST(D1)+1) AND H>REF(H,1) AND BARSLAST(D1)>BARSLAST(G1);
D2:=D1 AND L=LLV(D1L,BARSLAST(G1)+1) AND L<REF(L,1) AND BARSLAST(G1)>BARSLAST(D1);
G3:=G2 OR (FG0 AND REF(H,BARSLAST(FG0))>REF(H,BARSLAST(G2)) AND BARSLAST(D2)>BARSLAST(G2));
D3:=D2 OR (FD0 AND REF(L,BARSLAST(FD0))<REF(L,BARSLAST(D2)) AND BARSLAST(G2)>BARSLAST(D2));
GPB:IF(G1X,H,DRAWNULL),CIRCLEDOT,COLORYELLOW;
DPB:IF(D1X,L,DRAWNULL),CIRCLEDOT,COLORYELLOW;
MMM:="MA.MA1"(5),NODRAW,COLORRED;
NN:=G3;UU:=D3;
近期最低RAWLINE(UU,L,NN, H,0),COLORYELLOW;
近期最高RAWLINE(NN,H,UU, L,0),COLOR00FF00;
DRAWNUMBER(UU,L*0.99,L);
DRAWNUMBER(NN,H*1.02,H);
DRAWLINE(UU,L,REF(UU,1),REF(L,1),1),COLOR00FF00,LINETHICK1;
DRAWLINE(NN,H,REF(NN,1),REF(H,1),1),COLORFF00FF,LINETHICK1;
HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;
AAB:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);
{HIGHN日前的最高价=2*HIGHN+1日内最高价的最高值}
QY:=BACKSET(AAB,HIGHN+1);{若AA则将最近HIGHN+1周期置为1}
CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1);
{QY的HIGHN日过滤 AND 最高价=HIGHN+1日内最高价的最高值}
DRAWICON(CC,H*1.005,2);
DDD:=BARSLAST(CC);{上次CC距今天数}
GDTS:=IF(CC,CURRBARSCOUNT,0);{如果CC,返回到最后交易日的周,否则返回0}
DINGBU:=IF(DDD,REF(H,DDD),H);{顶部}
DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS);
DINGBU1:=REF(DINGBU,DDD+1);
GDCS1:=CONST(DINGBUTS);
DINGBUTS1:=REF(DINGBUTS,DDD+1);
GDCS2:=CONST(DINGBUTS1);
DINGBU2:=REF(DINGBU1,DDD+1);
MMMM:=IF(CURRBARSCOUNT>GDCS2,0,1);
高点压力RAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1,H,1) COLORGREEN,DOTLINE;
压力ARAWLINE(CURRBARSCOUNT=GDCS2,H,ISLASTBAR,REF(H,GDCS2-1),1),COLOR0055FF,DOTLINE;
压力BRAWLINE(CURRBARSCOUNT=GDCS1,H,ISLASTBAR,REF(H,GDCS1-1),1),COLORYELLOW,DOTLINE;
AAA1:=REF(L,LOWN)=LLV(L,2*LOWN+1);
QY1:=BACKSET(AAA1,LOWN+1);
CCC1:=FILTER(QY1,LOWN) AND L=LLV(L,LOWN+1);
{DRAWICON(CC1,L*0.98,1);}
DD1:=BARSLAST(CCC1);
DDTS:=IF(CCC1,CURRBARSCOUNT,0);
YDB:=IF(DD1,REF(L,DD1),L);
DDTS1:=IF(DD1,REF(DDTS,DD1),DDTS);
DDCS1:=CONST(DDTS1);
ZDB:=REF(YDB,DD1+1);
DDTS2:=REF(DDTS1,DD1+1);
DDCS2:=CONST(DDTS2);
低点支撑RAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1,L,1) COLORRED,DOTLINE;
ZGSTAR:=(高点压力+低点支撑)/2;
ZGEND:=CONST((高点压力+低点支撑)/2);
STARDAY:=IF(DDCS2<GDCS2,DDCS2,GDCS2);
中轨RAWLINE(CURRBARSCOUNT=STARDAY,ZGSTAR,ISLASTBAR,ZGEND,1),POINTDOT,COLORFFBBFF,LINETHICK1;
TTT:=6;
A11:=REF(HIGH,6)=HHV(HIGH,2*TTT+1);
B11:=FILTER(A11,TTT);
C11:=BACKSET(B11,TTT+1);
D11:=FILTER(C11,TTT);
A22:=REF(LOW,TTT)=LLV(LOW,2*TTT+1);
B22:=FILTER(A22,TTT);
C22:=BACKSET(B22,TTT+1);
D22:=FILTER(C22,TTT);
E1:=(REF(LLV(LOW,2*TTT),1)+REF(HHV(HIGH,2*TTT),1))/2;
E2:=(HIGH+LOW)/2;
H1:=(D11 AND NOT(D22 AND E1>=E2)) OR BARSTATUS OR BARSCOUNT(CLOSE)=1;
L11:=(D22 AND NOT(D11 AND E1<E2));
H2:=D11 AND NOT(D22 AND E1>=E2);
X1:=REF(BARSLAST(H1),1)+1;
F1:=BACKSET(H1 AND COUNT(L11,X1)>0,LLVBARS(IF(L11,LOW,10000),X1));
GG1:=F1>REF(F1,1); I1:=BACKSET(GG1,2);
LDD:=I1>REF(I1,1);
LL2:=LDD OR BARSTATUS OR BARSCOUNT(CLOSE)=1;
X2:=REF(BARSLAST(LL2),1)+1;
F2:=BACKSET(LL2 AND COUNT(H2,X2)>0,HHVBARS(IF(H2,HIGH,0),X2));
GG2:=F2>REF(F2,1);
I2:=BACKSET(GG2,2);
HDD:=I2>REF(I2,1);
UUU:=BACKSET(BARSTATUS,BARSLAST(LDD)+1);
VV:=UUU>REF(UUU,1);
WW:=BACKSET(VV,REF(BARSLAST(LDD),1)+2);
XX:=WW>REF(WW,1);
UU2:=BACKSET(BARSTATUS,BARSLAST(HDD)+1);
VV2:=UU2>REF(UU2,1);
WW2:=BACKSET(VV2,REF(BARSLAST(HDD),1)+2);
XX2:=WW2>REF(WW2,1);
近低A:REF(L,BARSLAST(VV)),COLORWHITE,LINETHICK1,DOTLINE;
近低B:REF(L,BARSLAST(XX)),COLORLIRED,DOTLINE;
DRAWTEXT(CURRBARSCOUNT=8,高点压力,STRCAT('压力延伸:',CON2STR(高点压力,2))),COLORCYAN;
DRAWTEXT(CURRBARSCOUNT=8,低点支撑,STRCAT('支撑延伸:',CON2STR(低点支撑,2))),COLORLIRED;
DRAWTEXT(CURRBARSCOUNT=15,中轨,STRCAT('中轨:',CON2STR(中轨,2))),COLORYELLOW;
DRAWTEXT(CURRBARSCOUNT=20,压力A*0.995,STRCAT('压力A:',CON2STR(压力A,2))),COLORGREEN;
DRAWTEXT(CURRBARSCOUNT=12,压力B*0.995,STRCAT('压力B:',CON2STR(压力B,2))),COLORBLUE;
DRAWTEXT(CURRBARSCOUNT=12,近低A*1.005,STRCAT('←近低A:',CON2STR(近低A,2))),COLORRED;
DRAWTEXT(CURRBARSCOUNT=20,近低B*1.005,STRCAT('←近低B:',CON2STR(近低B,2))),COLOR0018D8;
{把涨幅和跌幅在4%以上的K线换个颜色显示}
STICKLINE((C-REF(C,1))/REF(C,1)*100>=4,C,O,3,0),COLOR7F00FF;
STICKLINE((C-REF(C,1))/REF(C,1)*100<-4,C,O,3,0),COLORFF7F00;
{涨停和跌停K线加色}
STICKLINE(C<0.905*REF(C,1),C,O,3,0),COLOR00FF00;
STICKLINE(C>1.095*REF(C,1),C,O,3,0),COLORRED;
{倍量加黄色}
STICKLINE(V/REF(V,1)>1.95,OPEN,CLOSE,1.0,0),COLOR00FFFF;

qaz88512156 发表于 2016-3-29 21:36


                   不回复,源码不全!
Var1:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*100;   
Var2:=SMA(Var1,3,1);   
Var3:=SMA(Var2,3,1);   
Var4:=SMA(Var3,3,1);   
波: Var3;   
段: Var4;   
Var6:=CROSS(Var3,Var4) AND Var3<20;   
DRAWTEXT(FILTER(Var6,10)=1,40,'抄底'),LINETHICK3 ;   
STICKLINE(FILTER(Var6,10)=1,0,30,10,0),COLORGREEN ;   
Var7:=CROSS(Var4,Var3) AND Var3>80;   
STICKLINE(FILTER(Var7,5)=1,80,100,10,0),COLORYELLOW ;   
DRAWTEXT(FILTER(Var7,5)=1,70,'逃顶'),LINETHICK3 ,COLORYELLOW;   
Var8:=CROSS(Var2,Var3) AND Var3>80 AND Var3>Var4;   
STICKLINE(Var8,85,100,10,0) ;   
90 ;   
0;   

随小风 发表于 2016-3-31 10:33

                           :):)

sijjis 发表于 2016-2-20 21:12

多年来我一直使用,这次奉献给大家

zjtz298 发表于 2016-2-20 21:13

谢谢楼主分享

御道 发表于 2016-2-20 21:20


谢谢楼主分享

七里屿 发表于 2016-2-20 21:20

多谢分享。

逗逗乐 发表于 2016-2-20 21:22

谢谢分享,辛苦了。。

hongker 发表于 2016-2-20 21:24

这次奉献给大家

乔治禅 发表于 2016-2-20 21:27

谢谢楼主分享

曲径通幽1 发表于 2016-2-20 21:28

谢谢分享辛苦了。。

清雅君 发表于 2016-2-20 21:31

向老师学习学习学习

HBTSwolf 发表于 2016-2-20 21:34

感谢老师无私奉献

股海觅真 发表于 2016-2-20 21:36

股海茫茫,有灯塔指引方向,钱海涛涛,驾量舟收获勤劳! 灯塔泛指王子的量学!感恩!

曲径通幽1 发表于 2016-2-20 21:43

谢谢分享辛苦了。。

小小江 发表于 2016-2-20 21:43

谢谢分享。

天涯数码 发表于 2016-2-20 21:43

谢谢分享!
页: [1] 2 3 4 5 6
查看完整版本: 很好的抄底指标(源码