您现在的位置:程序化交易>> 期货公式>> 博易大师>> 博易大师知识>>正文内容

请吧这个文华指标改成博易的,谢谢 [博易POBO]

咨询内容:

请吧这个文华指标改成博易的,谢谢

这个是标出波浪的峰谷点差和连接线的主图附加指标
 //M:=5;
//N:=10;
A1:=REF(HIGH,N)=HHV(HIGH,2*N+1);
B1:=FILTER(A1,N);
C1:=BACKSET(B1,N+1);
D1:=FILTER(C1,N);
//{高点}
A2:=REF(LOW,N)=LLV(LOW,2*N+1);
B2:=FILTER(A2,N);
C2:=BACKSET(B2,N+1);
D2:=FILTER(C2,N);
//{低点}
E1:=(REF(LLV(LOW,2*N),1)+REF(HHV(HIGH,2*N),1))/2;
E2:=(HIGH+LOW)/2;
H1:=(D1 AND NOT((D2 AND E1>=E2))) OR ISLASTBAR OR BARSCOUNT(CLOSE)=1;


L1:=(D2 AND NOT((D1 AND E1<E2))),NODRAW;
H2:=D1 AND NOT((D2 AND E1>=E2));
X1:=REF(BARSLAST(H1),1)+1;
F1:=BACKSET(H1 AND COUNT(L1,X1)>0,LLVBARS(LOW,X1)+1);
//LLVBARS(IF(L1,LOW,N000),X1)+1,NODRAW;
//DRAWTEXT(X1,L,'X1');
//DRAWTEXT(F1,H,'F1');
G1:=F1>REF(F1,1);
I1:=BACKSET(G1,1);
LD:=I1>REF(I1,1);
L2:=LD OR ISLASTBAR OR BARSCOUNT(CLOSE)=1;
X2:=REF(BARSLAST(L2),1)+1;
F2:=BACKSET(L2 AND COUNT(H2,X2)>0,HHVBARS(H,X2)+1);

G2:=F2>REF(F2,1);
I2:=BACKSET(G2,1);
HD:=I2>REF(I2,1);
K1:=BACKSET(HD&&H>HV(H,BARSLAST(LD)),BARSLAST(LD));
K2:=BACKSET(LD&&L<LV(L,BARSLAST(HD)),BARSLAST(HD));
HH:=HD&&NOT(LD)&&REFX1(K1<>1,1);
LL:=LD&&NOT(HD)&&REFX1(K2<>1,1);

//{过滤后高点}
DRAWLINE1(LL,L,HH,H,0),COLORRED,POINTDOT;
DRAWLINE1(HH,H,LL,L,0),COLORGREEN,POINTDOT;

DRAWNUMBER1(HH,H+M*MINPRICE,H-VALUEWHEN(LL,L),0),COLORGRAY;
DRAWNUMBER1(LL,L-M*MINPRICE,L-VALUEWHEN(HH,H),0),VALIGN0,COLORGRAY;

 

 来源:程序化99网( WWW.CXH99.COM )

博易技术人员: M:=5;
N:=10;
A1:=REF(HIGH,N)=HHV(HIGH,2*N+1);
B1:=FILTER(A1,N);
C1:=BACKSET(B1,N+1);
D1:=FILTER(C1,N);
//{高点}
A2:=REF(LOW,N)=LLV(LOW,2*N+1);
B2:=FILTER(A2,N);
C2:=BACKSET(B2,N+1);
D2:=FILTER(C2,N);
//{低点}
E1:=(REF(LLV(LOW,2*N),1)+REF(HHV(HIGH,2*N),1))/2;
E2:=(HIGH+LOW)/2;
H1:=(D1 AND NOT((D2 AND E1>=E2))) OR ISLASTBAR OR BARSCOUNT(CLOSE)=1;


L1:=(D2 AND NOT((D1 AND E1<E2))),NODRAW;
H2:=D1 AND NOT((D2 AND E1>=E2));
X1:=REF(BARSLAST(H1),1)+1;
F1:=BACKSET(H1 AND COUNT(L1,X1)>0,LLVBARS(LOW,X1)+1);
//LLVBARS(IF(L1,LOW,N000),X1)+1,NODRAW;
//DRAWTEXT(X1,L,'X1');
//DRAWTEXT(F1,H,'F1');
G1:=F1>REF(F1,1);
I1:=BACKSET(G1,1);
LD:=I1>REF(I1,1);
L2:=LD OR ISLASTBAR OR BARSCOUNT(CLOSE)=1;
X2:=REF(BARSLAST(L2),1)+1;
F2:=BACKSET(L2 AND COUNT(H2,X2)>0,HHVBARS(H,X2)+1);

G2:=F2>REF(F2,1);
I2:=BACKSET(G2,1);
HD:=I2>REF(I2,1);
K1:=BACKSET(HD&&H>=HHV(H,BARSLAST(LD)),BARSLAST(LD));
K2:=BACKSET(LD&&L<=LLV(L,BARSLAST(HD)),BARSLAST(HD));
HH:=HD&&NOT(LD)&&REFX(K1<>1,1);
LL:=LD&&NOT(HD)&&REFX(K2<>1,1);

//{过滤后高点}
DRAWLINE(LL,L,HH,H,0),COLORRED,POINTDOT;
DRAWLINE(HH,H,LL,L,0),COLORGREEN,POINTDOT;

DRAWNUMBER(HH,H+M,H-VALUEWHEN(LL,L),0),COLORGRAY; 来源 程序化久久网

 

有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友

可联系技术人员 QQ: 262069696  点击在线交流或微信号:cxh99cxh99  进行 有偿收费 编写!

怎么收费,代编流程等详情请点击阅读!

(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)


【字体: 】【打印文章】【查看评论

相关文章

    没有相关内容