软件名称:[B]一般性的波段主图[/B]
软件类型:国产软件
运行环境:Win9X/2000/XP/2003/
软件语言:简体中文
授权方式:解密版
软件大小:16.0 KB
官方主页:Home Page
更新时间:2009-01-17 20:44:41
软件简介:
一般性的波段主图
源码 一般性 且不好多解释 大家随便批
-----------------------------
input:n1(5,1,20),n2(5,5,50),n3(12,3,50);
DRAWGBKlast(c,strip(RGB(0,0,60),RGB(0,0,60),0));
M7:MA(C,7),colorffffff,linethick0;
M89:MA(C,89),COLORRED;
{波段短线}
YF_DDI:=(AMOUNT / VOL);
YF_JJ:=((OPEN + CLOSE) / 2);
YF_PJJ:=0;
YF_DDING:=EMA(CLOSE,6);
YF_MMD:=MA(YF_DDING,1);
YF_XXD:=EMA(CLOSE,18);
YF_YYZ:=REF(YF_MMD,1);
YF_XXD1:=REF(YF_XXD,1);
YF_YYZ1:=BARSCOUNT(C);
YF_TDCG:=IF((YF_YYZ1 = 1),0,(((YF_MMD - YF_YYZ) / YF_YYZ) * 100));
YF_ZFD:=IF((YF_YYZ1 = 1),0,(((YF_XXD - YF_XXD1) / YF_XXD1) * 100));
YF_JSD2:=REF(CLOSE,1);
CLOSE1:=IF((YF_YYZ1 = 1),0,(((CLOSE - YF_JSD2) / YF_JSD2) * 100));
YF_JZDF:=IF((YF_YYZ1 = 1),((CLOSE + OPEN) / 2),YF_YYZ);
YF_DCGJ:=YF_MMD;
JJ0:=YF_YYZ;
JJ1:=REF(YF_MMD,2);
JJ2:=(((YF_DCGJ + JJ0) + JJ1) / 3);
JJ02:=(((ABS((YF_DCGJ - JJ2)) + ABS((JJ0 - JJ2))) + ABS((JJ1 - JJ2))) / 3);
SS:=REF(YF_TDCG,1);
YF_ZFD1:=REF(YF_TDCG,2);
YF_ZFD2:=IF((YF_YYZ1 < 3),0,((JJ02 / YF_DCGJ) * 100));
YF_DHPXS:=IF((YF_YYZ1 < 3),0,IF((((YF_TDCG < 0) AND (SS < 0)) AND (YF_ZFD1 < 0)),(0 - 1),1));
SS:=REF(YF_TDCG,1);
YF_YZFZ:=IF((((YF_YYZ1 > 11) AND (SS < 0)) AND (YF_TDCG > 0)),1,0);
YF_JSD21:=BARSLAST((YF_YZFZ = 1));
YF_JSD:=REF(YF_JSD21,1);
A:=IF((((YF_YYZ1 > 11) AND (SS < 0)) AND (YF_TDCG > 0)),(YF_JSD + 1),YF_JSD);
YF_PJJ:=IF((((YF_YYZ1 > 11) AND (SS > 0)) AND (YF_TDCG < 0)),1,0);
YF_JSD11:=YF_JZDF;
DMRJ:=YF_JZDF;
DMCJ:=IF(((YF_YYZ1 > 11) AND (YF_JSD11 < OPEN)),OPEN,YF_JZDF);
YF_DMRJ:=IF(((YF_YYZ1 > 11) AND (DMRJ > OPEN)),OPEN,YF_JZDF);
YF_DMCJ:=0;
YF_DCG1:=REF(YF_JZDF,1);
YF_BDF5:=IF(((((YF_TDCG > 0.5) AND ((YF_ZFD2 > 0.215) OR (LOW > YF_JZDF))) AND (CLOSE >= OPEN)) AND ((CLOSE >= 200) OR ((CLOSE < 200) AND (CLOSE1 < 11)))),1,0);
YF_DMR:=IF((((YF_TDCG < (0 - 0.3)) AND ((YF_ZFD2 > 0.2) OR (HIGH < YF_JZDF))) AND ((OPEN >= CLOSE) OR (CLOSE1 < (0 - 1)))),1,0);
YF_DKS1:=BARSSINCE(YF_BDF5);
YF_TDMR:=BARSSINCE(YF_DMR);
YF_DMR:=(YF_DMR OR (BARPOS = 1));
YF_DCGJ1:=((COUNT(YF_BDF5,BARSLAST(YF_DMR)) = 1) AND YF_BDF5);
YF_DMRBUY:=((COUNT(YF_DMR,BARSLAST(YF_BDF5)) = 1) AND YF_DMR);
YF_DMCSELL:=BARSLAST(YF_DMRBUY);
YF_DCG10:=BARSLAST(YF_DCGJ1);
YF_DCG11:=((SUM(YF_DMRBUY,YF_DCG10) = 0) * YF_DCG10);
YF_DCGREAL:=REF(DMCJ,YF_DCG11);
YF_DMRJ11:=REF(YF_DCGREAL,1);
YF_DMRJ1:=IF((YF_DCGJ1 = 1),(((CLOSE - DMCJ) / DMCJ) * 100),(((YF_DMRJ - YF_DMRJ11) / YF_DMRJ11) * 100));
YF_DCG:=IF((((YF_DCG11 = 0) AND (YF_DCGJ1 = 0)) AND (YF_DMRBUY = 0)),0,YF_DMRJ1);
短买:YF_DCGJ1,LINETHICK0,colorred;
短卖:YF_DMRBUY,LINETHICK0,colorblue;
短持:YF_DCG11,LINETHICK0,colorff00ff;
STICKLINE((短买 = 1),OPEN,CLOSE,6,0),color0000bb;
STICKLINE((短买 = 1),OPEN,CLOSE,4,0),color0000cc;
STICKLINE((短买 = 1),OPEN,CLOSE,2,0),color0000dd;
STICKLINE((短持 > 0),OPEN,CLOSE,0,0),colorFFBBFF;
STICKLINE((短持 > 0),OPEN,CLOSE,6,0),colorFF44FF;
STICKLINE((短持 > 0),OPEN,CLOSE,5,0),colorFF66FF;
STICKLINE((短持 > 0),OPEN,CLOSE,4,0),colorFF88FF;
STICKLINE((短持 > 0),OPEN,CLOSE,3,0),colorFF99FF;
STICKLINE((短持 > 0),OPEN,CLOSE,2,0),colorFFAAFF;
STICKLINE((短持 > 0),OPEN,CLOSE,1,0),colorFFBBFF;
STICKLINE((短卖= 1),OPEN,CLOSE,0,0),colorFF0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,6,0),colorAA0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,5,0),colorBB0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,4,0),colorCC0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,3,0),colorDD0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,2,0),colorEE0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,1,0),colorFF0000;
短操盘状态:IF((短买 = 1),1,IF((短持 > 0),2,IF((短卖 = 1),9,0))),LINETHICK0;
明日空间买卖点:EMA(CLOSE,6),LINETHICK0;
{局部整理顶底压力}
A1:=REF(HIGH,3)=HHV(HIGH,2*3+1); B1:=FILTER(A1,3); C1:=BACKSET(B1,3+1); D1:=FILTER(C1,3);
A2:=REF(LOW,3)=LLV(LOW,2*3+1); B2:=FILTER(A2,3); C2:=BACKSET(B2,3+1); D2:=FILTER(C2,3);
E1:=(REF(LLV(LOW,2*3),1)+REF(HHV(HIGH,2*3),1))/2; E2:=(HIGH+LOW)/2;
H1:=(D1 AND NOT(D2 AND E1>=E2)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;
H2:=D1 AND NOT(D2 AND E1>=E2);
L1:=D2 AND NOT(D1 AND E1=E2);
X1:=REF(BARSLAST(H1),1)+1; F1:=BACKSET(H1 AND COUNT(L1,X1)>0,LLVBARS(IF(L1,LOW,10000),X1));
G1:=F1>REF(F1,1); I1:=BACKSET(G1,2); LD:=I1>REF(I1,1);
L2:=LD OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;
X2:=REF(BARSLAST(L2),1)+1; F2:=BACKSET(L2 AND COUNT(H2,X2)>0,HHVBARS(IF(H2,HIGH,0),X2));
G2:=F2>REF(F2,1); I2:=BACKSET(G2,2); HD:=I2>REF(I2,1);
J1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HD),BARSLAST(LD))+1); J2:=J1>REF(J1,1);
A3:=H; B3:=REF(H,REF(BARSLAST(HD),1)+1)>REF(H,REF(BARSLAST(HD),1)+2+REF(BARSLAST(HD),REF(BARSLAST(HD),1)+2));
D3:=A3 AND B3 AND HD; E3:=BACKSET(D3,REF(BARSLAST(HD),1)+2); HH:=E3>REF(E3,1);
A4:=L>REF(L,REF(BARSLAST(LD),1)+1);
B4:=REF(L,REF(BARSLAST(LD),1)+1); D4:=A4 AND B4 AND LD; E4:=BACKSET(D4,REF(BARSLAST(LD),1)+2); LL:=E4>REF(E4,1);{找出全部长期低点}
{DRAWICON(HH,H,8),ALIGN1;
DRAWICON(LL,L,7),ALIGN1;}
H3:=HH OR BARSTATUS=2 OR BARSCOUNT(C)=1;
X3:=REF(BARSLAST(H3),1)+1; F3:=BACKSET(H3 AND COUNT(LL,X3)>0,LLVBARS(IF(LL,L,POW(10,20)),X3));
G3:=F3>REF(F3,1); I3:=BACKSET(G3,2); LZ:=I3>REF(I3,1);
L4:=LZ OR BARSTATUS=2 OR BARSCOUNT(C)=1;
X4:=REF(BARSLAST(L4),1)+1; F4:=BACKSET(L4 AND COUNT(HH,X4)>0,HHVBARS(IF(HH,H,-POW(10,20)),X4));
G4:=F4>REF(F4,1); I4:=BACKSET(G4,2); HZ:=I4>REF(I4,1);
K1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HZ),BARSLAST(LZ))+1); K2:=K1>REF(K1,1);
UU:=BACKSET(BARSTATUS=2,BARSLAST(LD)+1);
VV:=UU>REF(UU,1);
WW:=BACKSET(VV,REF(BARSLAST(LD),1)+2);
XX:=WW>REF(WW,1);
DRAWLINE(XX,L,VV,L,1),COLORd3b3d3;
UU2:=BACKSET(BARSTATUS=2,BARSLAST(HD)+1);
VV2:=UU2>REF(UU2,1);
WW2:=BACKSET(VV2,REF(BARSLAST(HD),1)+2);
XX2:=WW2>REF(WW2,1);
DRAWLINE(XX2,H,VV2,H,1),COLORd3b3d3;
前一低:REF(L,BARSLAST(VV)),COLORred,dotline;
前二低:REF(L,BARSLAST(XX)),COLORred,dotline;
前一高:REF(H,BARSLAST(VV2)),COLOR778899,dotline;
前二高:REF(H,BARSLAST(XX2)),COLOR778899,dotline;
{大K线提示}
STICKLINE(c/ref(c,1)>1.04,o,c,8,0),coloryellow;
STICKLINE(c/ref(c,1)>1.04,h,c,0 ,0),coloryellow;
STICKLINE(c/ref(c,1)>1.04,l,o,0 ,0),coloryellow;
STICKLINE(c/ref(c,1)<0.96,o,c,8,1),color008800;
STICKLINE(c/ref(c,1)<0.96,h,o,0 ,0),color008800;
STICKLINE(c/ref(c,1)<0.96,l,c,0 ,0),color008800;
partline(m7,m7<ref(m7,1),rgb(0,255,0),m7>=ref(m7,1),rgb(255,255,255));
partline(m89,m89<ref(m89,1)),colorblue;
-----------------------------
input:n1(5,1,20),n2(5,5,50),n3(12,3,50);
DRAWGBKlast(c,strip(RGB(0,0,60),RGB(0,0,60),0));
M7:MA(C,7),colorffffff,linethick0;
M89:MA(C,89),COLORRED;
{波段短线}
YF_DDI:=(AMOUNT / VOL);
YF_JJ:=((OPEN + CLOSE) / 2);
YF_PJJ:=0;
YF_DDING:=EMA(CLOSE,6);
YF_MMD:=MA(YF_DDING,1);
YF_XXD:=EMA(CLOSE,18);
YF_YYZ:=REF(YF_MMD,1);
YF_XXD1:=REF(YF_XXD,1);
YF_YYZ1:=BARSCOUNT(C);
YF_TDCG:=IF((YF_YYZ1 = 1),0,(((YF_MMD - YF_YYZ) / YF_YYZ) * 100));
YF_ZFD:=IF((YF_YYZ1 = 1),0,(((YF_XXD - YF_XXD1) / YF_XXD1) * 100));
YF_JSD2:=REF(CLOSE,1);
CLOSE1:=IF((YF_YYZ1 = 1),0,(((CLOSE - YF_JSD2) / YF_JSD2) * 100));
YF_JZDF:=IF((YF_YYZ1 = 1),((CLOSE + OPEN) / 2),YF_YYZ);
YF_DCGJ:=YF_MMD;
JJ0:=YF_YYZ;
JJ1:=REF(YF_MMD,2);
JJ2:=(((YF_DCGJ + JJ0) + JJ1) / 3);
JJ02:=(((ABS((YF_DCGJ - JJ2)) + ABS((JJ0 - JJ2))) + ABS((JJ1 - JJ2))) / 3);
SS:=REF(YF_TDCG,1);
YF_ZFD1:=REF(YF_TDCG,2);
YF_ZFD2:=IF((YF_YYZ1 < 3),0,((JJ02 / YF_DCGJ) * 100));
YF_DHPXS:=IF((YF_YYZ1 < 3),0,IF((((YF_TDCG < 0) AND (SS < 0)) AND (YF_ZFD1 < 0)),(0 - 1),1));
SS:=REF(YF_TDCG,1);
YF_YZFZ:=IF((((YF_YYZ1 > 11) AND (SS < 0)) AND (YF_TDCG > 0)),1,0);
YF_JSD21:=BARSLAST((YF_YZFZ = 1));
YF_JSD:=REF(YF_JSD21,1);
A:=IF((((YF_YYZ1 > 11) AND (SS < 0)) AND (YF_TDCG > 0)),(YF_JSD + 1),YF_JSD);
YF_PJJ:=IF((((YF_YYZ1 > 11) AND (SS > 0)) AND (YF_TDCG < 0)),1,0);
YF_JSD11:=YF_JZDF;
DMRJ:=YF_JZDF;
DMCJ:=IF(((YF_YYZ1 > 11) AND (YF_JSD11 < OPEN)),OPEN,YF_JZDF);
YF_DMRJ:=IF(((YF_YYZ1 > 11) AND (DMRJ > OPEN)),OPEN,YF_JZDF);
YF_DMCJ:=0;
YF_DCG1:=REF(YF_JZDF,1);
YF_BDF5:=IF(((((YF_TDCG > 0.5) AND ((YF_ZFD2 > 0.215) OR (LOW > YF_JZDF))) AND (CLOSE >= OPEN)) AND ((CLOSE >= 200) OR ((CLOSE < 200) AND (CLOSE1 < 11)))),1,0);
YF_DMR:=IF((((YF_TDCG < (0 - 0.3)) AND ((YF_ZFD2 > 0.2) OR (HIGH < YF_JZDF))) AND ((OPEN >= CLOSE) OR (CLOSE1 < (0 - 1)))),1,0);
YF_DKS1:=BARSSINCE(YF_BDF5);
YF_TDMR:=BARSSINCE(YF_DMR);
YF_DMR:=(YF_DMR OR (BARPOS = 1));
YF_DCGJ1:=((COUNT(YF_BDF5,BARSLAST(YF_DMR)) = 1) AND YF_BDF5);
YF_DMRBUY:=((COUNT(YF_DMR,BARSLAST(YF_BDF5)) = 1) AND YF_DMR);
YF_DMCSELL:=BARSLAST(YF_DMRBUY);
YF_DCG10:=BARSLAST(YF_DCGJ1);
YF_DCG11:=((SUM(YF_DMRBUY,YF_DCG10) = 0) * YF_DCG10);
YF_DCGREAL:=REF(DMCJ,YF_DCG11);
YF_DMRJ11:=REF(YF_DCGREAL,1);
YF_DMRJ1:=IF((YF_DCGJ1 = 1),(((CLOSE - DMCJ) / DMCJ) * 100),(((YF_DMRJ - YF_DMRJ11) / YF_DMRJ11) * 100));
YF_DCG:=IF((((YF_DCG11 = 0) AND (YF_DCGJ1 = 0)) AND (YF_DMRBUY = 0)),0,YF_DMRJ1);
短买:YF_DCGJ1,LINETHICK0,colorred;
短卖:YF_DMRBUY,LINETHICK0,colorblue;
短持:YF_DCG11,LINETHICK0,colorff00ff;
STICKLINE((短买 = 1),OPEN,CLOSE,6,0),color0000bb;
STICKLINE((短买 = 1),OPEN,CLOSE,4,0),color0000cc;
STICKLINE((短买 = 1),OPEN,CLOSE,2,0),color0000dd;
STICKLINE((短持 > 0),OPEN,CLOSE,0,0),colorFFBBFF;
STICKLINE((短持 > 0),OPEN,CLOSE,6,0),colorFF44FF;
STICKLINE((短持 > 0),OPEN,CLOSE,5,0),colorFF66FF;
STICKLINE((短持 > 0),OPEN,CLOSE,4,0),colorFF88FF;
STICKLINE((短持 > 0),OPEN,CLOSE,3,0),colorFF99FF;
STICKLINE((短持 > 0),OPEN,CLOSE,2,0),colorFFAAFF;
STICKLINE((短持 > 0),OPEN,CLOSE,1,0),colorFFBBFF;
STICKLINE((短卖= 1),OPEN,CLOSE,0,0),colorFF0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,6,0),colorAA0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,5,0),colorBB0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,4,0),colorCC0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,3,0),colorDD0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,2,0),colorEE0000;
STICKLINE((短卖 = 1),OPEN,CLOSE,1,0),colorFF0000;
短操盘状态:IF((短买 = 1),1,IF((短持 > 0),2,IF((短卖 = 1),9,0))),LINETHICK0;
明日空间买卖点:EMA(CLOSE,6),LINETHICK0;
{局部整理顶底压力}
A1:=REF(HIGH,3)=HHV(HIGH,2*3+1); B1:=FILTER(A1,3); C1:=BACKSET(B1,3+1); D1:=FILTER(C1,3);
A2:=REF(LOW,3)=LLV(LOW,2*3+1); B2:=FILTER(A2,3); C2:=BACKSET(B2,3+1); D2:=FILTER(C2,3);
E1:=(REF(LLV(LOW,2*3),1)+REF(HHV(HIGH,2*3),1))/2; E2:=(HIGH+LOW)/2;
H1:=(D1 AND NOT(D2 AND E1>=E2)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;
H2:=D1 AND NOT(D2 AND E1>=E2);
L1:=D2 AND NOT(D1 AND E1=E2);
X1:=REF(BARSLAST(H1),1)+1; F1:=BACKSET(H1 AND COUNT(L1,X1)>0,LLVBARS(IF(L1,LOW,10000),X1));
G1:=F1>REF(F1,1); I1:=BACKSET(G1,2); LD:=I1>REF(I1,1);
L2:=LD OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1;
X2:=REF(BARSLAST(L2),1)+1; F2:=BACKSET(L2 AND COUNT(H2,X2)>0,HHVBARS(IF(H2,HIGH,0),X2));
G2:=F2>REF(F2,1); I2:=BACKSET(G2,2); HD:=I2>REF(I2,1);
J1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HD),BARSLAST(LD))+1); J2:=J1>REF(J1,1);
A3:=H; B3:=REF(H,REF(BARSLAST(HD),1)+1)>REF(H,REF(BARSLAST(HD),1)+2+REF(BARSLAST(HD),REF(BARSLAST(HD),1)+2));
D3:=A3 AND B3 AND HD; E3:=BACKSET(D3,REF(BARSLAST(HD),1)+2); HH:=E3>REF(E3,1);
A4:=L>REF(L,REF(BARSLAST(LD),1)+1);
B4:=REF(L,REF(BARSLAST(LD),1)+1); D4:=A4 AND B4 AND LD; E4:=BACKSET(D4,REF(BARSLAST(LD),1)+2); LL:=E4>REF(E4,1);{找出全部长期低点}
{DRAWICON(HH,H,8),ALIGN1;
DRAWICON(LL,L,7),ALIGN1;}
H3:=HH OR BARSTATUS=2 OR BARSCOUNT(C)=1;
X3:=REF(BARSLAST(H3),1)+1; F3:=BACKSET(H3 AND COUNT(LL,X3)>0,LLVBARS(IF(LL,L,POW(10,20)),X3));
G3:=F3>REF(F3,1); I3:=BACKSET(G3,2); LZ:=I3>REF(I3,1);
L4:=LZ OR BARSTATUS=2 OR BARSCOUNT(C)=1;
X4:=REF(BARSLAST(L4),1)+1; F4:=BACKSET(L4 AND COUNT(HH,X4)>0,HHVBARS(IF(HH,H,-POW(10,20)),X4));
G4:=F4>REF(F4,1); I4:=BACKSET(G4,2); HZ:=I4>REF(I4,1);
K1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HZ),BARSLAST(LZ))+1); K2:=K1>REF(K1,1);
UU:=BACKSET(BARSTATUS=2,BARSLAST(LD)+1);
VV:=UU>REF(UU,1);
WW:=BACKSET(VV,REF(BARSLAST(LD),1)+2);
XX:=WW>REF(WW,1);
DRAWLINE(XX,L,VV,L,1),COLORd3b3d3;
UU2:=BACKSET(BARSTATUS=2,BARSLAST(HD)+1);
VV2:=UU2>REF(UU2,1);
WW2:=BACKSET(VV2,REF(BARSLAST(HD),1)+2);
XX2:=WW2>REF(WW2,1);
DRAWLINE(XX2,H,VV2,H,1),COLORd3b3d3;
前一低:REF(L,BARSLAST(VV)),COLORred,dotline;
前二低:REF(L,BARSLAST(XX)),COLORred,dotline;
前一高:REF(H,BARSLAST(VV2)),COLOR778899,dotline;
前二高:REF(H,BARSLAST(XX2)),COLOR778899,dotline;
{大K线提示}
STICKLINE(c/ref(c,1)>1.04,o,c,8,0),coloryellow;
STICKLINE(c/ref(c,1)>1.04,h,c,0 ,0),coloryellow;
STICKLINE(c/ref(c,1)>1.04,l,o,0 ,0),coloryellow;
STICKLINE(c/ref(c,1)<0.96,o,c,8,1),color008800;
STICKLINE(c/ref(c,1)<0.96,h,o,0 ,0),color008800;
STICKLINE(c/ref(c,1)<0.96,l,c,0 ,0),color008800;
partline(m7,m7<ref(m7,1),rgb(0,255,0),m7>=ref(m7,1),rgb(255,255,255));
partline(m89,m89<ref(m89,1)),colorblue;
[url=http://www.70822.com/soft/sort013/sort03/down-5644.html]一般性的波段主图[/url]