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

帮忙改改能在博易云上用的?谢谢 [博易POBO]

咨询内容:

帮忙改改能在博易云上用的?谢谢


DRAWGBK(C>0, RGB(1,1,1),RGB(1,1,1),0,'0',0);
STICKLINE(C>0,120,120,28,-1)COLORBLACK;
STICKLINE(C>0,100,100,28,-1)COLOR000080;
STICKLINE(C>0,80,80,28,-1)COLOR000080;
STICKLINE(C>0,50,50,28,-1)COLOR000080;
STICKLINE(C>0,20,20,28,-1)COLOR000080;
STICKLINE(C>0,0,0,28,-1)COLOR000080;
STICKLINE(C>0,-20,-20,28,-1)COLORBLACK;

RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:SMA(RSV,3,1)COLORCYAN;
D:SMA(K,3,1)COLORYELLOW;
J:3*K-2*D,COLORMAGENTA;


{K值,D值,J值的背离}
{------------------------------------------------------------------------------}
N:=5;
{}
J底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.J,N)=LLV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=LLV(KDJ.J,N+1),1))+1)>C AND 
REF(KDJ.J,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.J,N)=LLV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=LLV(KDJ.J,N+1),1))+1)<KDJ.J AND 
FILTER(BACKSET(REF(KDJ.J,N)=LLV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=LLV(KDJ.J,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.J,N)=LLV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=LLV(KDJ.J,N+1),KDJ.J,FILTER(J底背>0,5),KDJ.J,0),
COLORWHITE,DOTLINE;
DRAWTEXT(J底背,KDJ.J,'J底背'),COLORLIMAGENTA;
J顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.J,N)=HHV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=HHV(KDJ.J,N+1),1))+1)<C AND 
REF(KDJ.J,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.J,N)=HHV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=HHV(KDJ.J,N+1),1))+1)>KDJ.J AND 
FILTER(BACKSET(REF(KDJ.J,N)=HHV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=HHV(KDJ.J,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.J,N)=HHV(KDJ.J,2*N+1),N+1),N) AND KDJ.J=HHV(KDJ.J,N+1),KDJ.J,FILTER(J顶背>0,5),KDJ.J,0),
COLORGREEN,DOTLINE;
DRAWTEXT(J顶背,KDJ.J,'J顶背'),COLORMAGENTA;
{------------------------------------------------------------------------------}
K底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.K,N)=LLV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=LLV(KDJ.K,N+1),1))+1)>C AND 
REF(KDJ.K,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.K,N)=LLV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=LLV(KDJ.K,N+1),1))+1)<KDJ.K AND 
FILTER(BACKSET(REF(KDJ.K,N)=LLV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=LLV(KDJ.K,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.K,N)=LLV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=LLV(KDJ.K,N+1),KDJ.K,FILTER(K底背>0,5),KDJ.K,0),
COLORWHITE,DOTLINE;
DRAWTEXT(K底背,KDJ.K,'K底背'),COLORWHITE;
K顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.K,N)=HHV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=HHV(KDJ.K,N+1),1))+1)<C AND 
REF(KDJ.K,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.K,N)=HHV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=HHV(KDJ.K,N+1),1))+1)>KDJ.K AND 
FILTER(BACKSET(REF(KDJ.K,N)=HHV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=HHV(KDJ.K,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.K,N)=HHV(KDJ.K,2*N+1),N+1),N) AND KDJ.K=HHV(KDJ.K,N+1),KDJ.K,FILTER(K顶背>0,5),KDJ.K,0),
COLORGREEN,DOTLINE;
DRAWTEXT(K顶背,KDJ.K,'K顶背'),COLORLIBLUE;
{------------------------------------------------------------------------------}
D底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.D,N)=LLV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=LLV(KDJ.D,N+1),1))+1)>C AND 
REF(KDJ.D,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.D,N)=LLV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=LLV(KDJ.D,N+1),1))+1)<KDJ.D AND 
FILTER(BACKSET(REF(KDJ.D,N)=LLV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=LLV(KDJ.D,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.D,N)=LLV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=LLV(KDJ.D,N+1),KDJ.D,FILTER(D底背>0,5),KDJ.D,0),
COLORWHITE,DOTLINE;
DRAWTEXT(D底背,KDJ.D,'D底背'),COLORYELLOW;
D顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.D,N)=HHV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=HHV(KDJ.D,N+1),1))+1)<C AND 
REF(KDJ.D,BARSLAST(REF(FILTER(BACKSET(REF(KDJ.D,N)=HHV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=HHV(KDJ.D,N+1),1))+1)>KDJ.D AND 
FILTER(BACKSET(REF(KDJ.D,N)=HHV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=HHV(KDJ.D,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJ.D,N)=HHV(KDJ.D,2*N+1),N+1),N) AND KDJ.D=HHV(KDJ.D,N+1),KDJ.D,FILTER(D顶背>0,5),KDJ.D,0),
COLORGREEN,DOTLINE;
DRAWTEXT(D顶背,KDJ.D,'D顶背'),COLOR4080FF;


{以下是金叉死叉背离}
{}
A2:=BARSLAST(REF(CROSS(K,D),1));
B2:=REF(C,A2+1)>C AND REF(K,A2+1)<K AND CROSS(K,D);
DRAWTEXT((B2>0),-10,'_金叉底背'),COLORLIRED;
STICKLINE((B2>0),-10,50,0,-1)COLORLIRED;
{DRAWLINE((B2>0),K,B2,K,0),COLORLIRED,DOTLINE;}{金叉底背画线};
{}
C2:=BARSLAST(REF(CROSS(D,K),1));
D2:=REF(C,C2+1)<C AND REF(K,C2+1)>K AND CROSS(D,K);
DRAWTEXT((D2>0),110,'_死叉顶背'),COLORLICYAN;
STICKLINE((D2>0),110,50,0,-1)COLORLICYAN;
{DRAWLINE((D2>0),K,D2,K,0),COLORGREEN,DOTLINE;}{死叉顶背画线};


 

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

博易技术人员: STICKLINE(C>0,120,120,28,-1),COLORBLACK;
STICKLINE(C>0,100,100,28,-1),COLOR000080;
STICKLINE(C>0,80,80,28,-1),COLOR000080;
STICKLINE(C>0,50,50,28,-1),COLOR000080;
STICKLINE(C>0,20,20,28,-1),COLOR000080;
STICKLINE(C>0,0,0,28,-1),COLOR000080;
STICKLINE(C>0,-20,-20,28,-1),COLORBLACK;

RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:SMA(RSV,3,1),COLORCYAN;
D:SMA(K,3,1),COLORYELLOW;
J:3*K-2*D,COLORMAGENTA;


{K值,D值,J值的背离}
{------------------------------------------------------------------------------}
 KDJJ:=STKINDI('',6,'kdj.j',9,3,3);
 KDJK:=STKINDI('',6,'kdj.k',9,3,3);
 KDJD:=STKINDI('',6,'kdj.d',9,3,3);
N:=5;
{}
J底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJJ,N)=LLV(KDJJ,2*N+1),N+1),N) AND KDJJ=LLV(KDJJ,N+1),1))+1)>C AND 
REF(KDJJ,BARSLAST(REF(FILTER(BACKSET(REF(KDJJ,N)=LLV(KDJJ,2*N+1),N+1),N) AND KDJJ=LLV(KDJJ,N+1),1))+1)<KDJJ AND 
FILTER(BACKSET(REF(KDJJ,N)=LLV(KDJJ,2*N+1),N+1),N) AND KDJJ=LLV(KDJJ,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJJ,N)=LLV(KDJJ,2*N+1),N+1),N) AND KDJJ=LLV(KDJJ,N+1),KDJJ,FILTER(J底背>0,5),KDJJ,0),
COLORWHITE,POINTDOT;
DRAWTEXT(J底背,KDJJ,'J底背'),COLORMAGENTA;
J顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJJ,N)=HHV(KDJJ,2*N+1),N+1),N) AND KDJJ=HHV(KDJJ,N+1),1))+1)<C AND 
REF(KDJJ,BARSLAST(REF(FILTER(BACKSET(REF(KDJJ,N)=HHV(KDJJ,2*N+1),N+1),N) AND KDJJ=HHV(KDJJ,N+1),1))+1)>KDJJ AND 
FILTER(BACKSET(REF(KDJJ,N)=HHV(KDJJ,2*N+1),N+1),N) AND KDJJ=HHV(KDJJ,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJJ,N)=HHV(KDJJ,2*N+1),N+1),N) AND KDJJ=HHV(KDJJ,N+1),KDJJ,FILTER(J顶背>0,5),KDJJ,0),
COLORGREEN,POINTDOT;
DRAWTEXT(J顶背,KDJJ,'J顶背'),COLORMAGENTA;
{------------------------------------------------------------------------------}
K底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJK,N)=LLV(KDJK,2*N+1),N+1),N) AND KDJK=LLV(KDJK,N+1),1))+1)>C AND 
REF(KDJK,BARSLAST(REF(FILTER(BACKSET(REF(KDJK,N)=LLV(KDJK,2*N+1),N+1),N) AND KDJK=LLV(KDJK,N+1),1))+1)<KDJK AND 
FILTER(BACKSET(REF(KDJK,N)=LLV(KDJK,2*N+1),N+1),N) AND KDJK=LLV(KDJK,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJK,N)=LLV(KDJK,2*N+1),N+1),N) AND KDJK=LLV(KDJK,N+1),KDJK,FILTER(K底背>0,5),KDJK,0),
COLORWHITE,POINTDOT;
DRAWTEXT(K底背,KDJK,'K底背'),COLORWHITE;
K顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJK,N)=HHV(KDJK,2*N+1),N+1),N) AND KDJK=HHV(KDJK,N+1),1))+1)<C AND 
REF(KDJK,BARSLAST(REF(FILTER(BACKSET(REF(KDJK,N)=HHV(KDJK,2*N+1),N+1),N) AND KDJK=HHV(KDJK,N+1),1))+1)>KDJK AND 
FILTER(BACKSET(REF(KDJK,N)=HHV(KDJK,2*N+1),N+1),N) AND KDJK=HHV(KDJK,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJK,N)=HHV(KDJK,2*N+1),N+1),N) AND KDJK=HHV(KDJK,N+1),KDJK,FILTER(K顶背>0,5),KDJK,0),
COLORGREEN,POINTDOT;
DRAWTEXT(K顶背,KDJK,'K顶背'),COLORBLUE;
{------------------------------------------------------------------------------}
D底背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJD,N)=LLV(KDJD,2*N+1),N+1),N) AND KDJD=LLV(KDJD,N+1),1))+1)>C AND 
REF(KDJD,BARSLAST(REF(FILTER(BACKSET(REF(KDJD,N)=LLV(KDJD,2*N+1),N+1),N) AND KDJD=LLV(KDJD,N+1),1))+1)<KDJD AND 
FILTER(BACKSET(REF(KDJD,N)=LLV(KDJD,2*N+1),N+1),N) AND KDJD=LLV(KDJD,N+1),COLORWHITE,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJD,N)=LLV(KDJD,2*N+1),N+1),N) AND KDJD=LLV(KDJD,N+1),KDJD,FILTER(D底背>0,5),KDJD,0),
COLORWHITE,POINTDOT;
DRAWTEXT(D底背,KDJD,'D底背'),COLORYELLOW;
D顶背:REF(C,BARSLAST(REF(FILTER(BACKSET(REF(KDJD,N)=HHV(KDJD,2*N+1),N+1),N) AND KDJD=HHV(KDJD,N+1),1))+1)<C AND 
REF(KDJD,BARSLAST(REF(FILTER(BACKSET(REF(KDJD,N)=HHV(KDJD,2*N+1),N+1),N) AND KDJD=HHV(KDJD,N+1),1))+1)>KDJD AND 
FILTER(BACKSET(REF(KDJD,N)=HHV(KDJD,2*N+1),N+1),N) AND KDJD=HHV(KDJD,N+1),COLORGREEN,NODRAW;
DRAWLINE(FILTER(BACKSET(REF(KDJD,N)=HHV(KDJD,2*N+1),N+1),N) AND KDJD=HHV(KDJD,N+1),KDJD,FILTER(D顶背>0,5),KDJD,0),
COLORGREEN,POINTDOT;
DRAWTEXT(D顶背,KDJD,'D顶背'),COLOR4080FF;


{以下是金叉死叉背离}
{}
A2:=BARSLAST(REF(CROSS(K,D),1));
B2:=REF(C,A2+1)>C AND REF(K,A2+1)<K AND CROSS(K,D);
DRAWTEXT((B2>0),-10,'_金叉底背'),COLORRED;
STICKLINE((B2>0),-10,50,0,-1),COLORRED;
{DRAWLINE((B2>0),K,B2,K,0),COLORLIRED,DOTLINE;}{金叉底背画线};
{}
C2:=BARSLAST(REF(CROSS(D,K),1));
D2:=REF(C,C2+1)<C AND REF(K,C2+1)>K AND CROSS(D,K);
DRAWTEXT((D2>0),110,'_死叉顶背'),COLORCYAN;
STICKLINE((D2>0),110,50,0,-1),COLORCYAN;
{DRAWLINE((D2>0),K,D2,K,0),COLORGREEN,DOTLINE;}{死叉顶背画线}; 来源 程序化久久网

 

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

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

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

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


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

相关文章

    没有相关内容