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

请老师改成博弈指标 [博易POBO]

咨询内容:

请老师改成博弈指标

N:=120;
CURRBARSCOUNT:=DATACOUNT-BARPOS+1;
KT:=BARSLAST(CURRBARSCOUNT=N);
GD:=REFX(IF(ISLASTBAR=1,HHV(H,KT),0),10000);//{高点}
DD:=REFX(IF(ISLASTBAR=1,LLV(L,KT),0),10000);//{低点}
KJ:=GD-DD;//{高低点差值=分区高度}
GD4:=IF(CURRBARSCOUNT<=N/30+16,GD,DRAWNULL);
高:=IF(CURRBARSCOUNT<=N/30+16,GD,DRAWNULL),COLORWHITE,COLOR00FFFF,PRECIS0;
低:=IF(CURRBARSCOUNT<=N/30+16,DD,DRAWNULL),COLORWHITE,COLORFFFF00,PRECIS0;


高区:IF(CURRBARSCOUNT<=N+16,GD,DRAWNULL),COLORWHITE,DASH,COLOR004080,PRECIS0;
低区:IF(CURRBARSCOUNT<=N+16,DD,DRAWNULL),COLORWHITE,DASH,COLOR004080,PRECIS0;


压力:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.809,DRAWNULL),COLORGREEN,COLOR00FF00,PRECIS0;
警示:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.618,DRAWNULL),COLOR00FFFF,PRECIS0;
突破:IF(CURRBARSCOUNT<=N/40+16,DD+KJ/2,DRAWNULL),COLORYELLOW,COLOR0000FF,PRECIS0;
强势: IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.382,DRAWNULL),COLORFF00FF,PRECIS0;
支撑:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.191,DRAWNULL),COLORRED,COLOR00FFFF,PRECIS0;
低涨:IF(CURRBARSCOUNT<=N/40+16,(C/LLV(LOW,KT)-1)*100,DRAWNULL),RGB(0,128,255),COLOR0000FF,NODRAW,PRECIS0;
天数:BARSLAST(L=DD),COLORWHITE,NODRAW,PRECIS0;




//{STICKLINE1(CURRBARSCOUNT=N/30,GD,DD,0,0),COLORGREEN;
//STICKLINE1(CURRBARSCOUNT=1,GD,DD,0,0),COLORGREEN;}
STICKLINE(CURRBARSCOUNT<=N/30,支撑,支撑,14,0),COLORFF00FF;

STICKLINE(CURRBARSCOUNT<=N/30,强势,强势,14,0),COLORFF00FF;
STICKLINE(CURRBARSCOUNT<=N/30,突破,突破,14,0),COLORABABAB;
STICKLINE(CURRBARSCOUNT<=N/30,警示,警示,14,0),COLOR00FFFF;

STICKLINE(CURRBARSCOUNT<=N/30,压力,压力,14,0),COLOR00FFFF;



DRAWTEXT(CURRBARSCOUNT=N/40+16,高,'高位:809'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,压力,'压力:681'),COLORMAGENTA,FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,警示,'警示:500'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,强势,'强势:382'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,支撑,'支撑:191'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,低,'低位:000'),FONTSIZE20,ALIGN2,VALIGN1;


M:=BARSLAST(CURRBARSCOUNT=N);
平衡:=IF(CURRBARSCOUNT<=N,DD+KJ/2,DRAWNULL),COLORWHITE,DOTLINE,COLOR004080,PRECIS0;
CD:=CURRBARSCOUNT,NODRAW;
STICKLINE(CD=46,HHV(高区,60),LLV(低区,60),1,0),COLORBLACK,COLOR004080;
STICKLINE(CD=120,HHV(高区,60),LLV(低区,60),1,0),COLORBLUE,COLOR004080;
STICKLINE(CD=1,HHV(高区,60),LLV(低区,60),0.1,0),RGB(0,0,0),COLOR004080;

DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.09,'【风险区】--高抛避险'),COLORGREEN,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.3,'【警示区】--逢高减仓'),COLORGREEN,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.45,'【突破区】--主力拉升'),COLORMAGENTA,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.55,'【拉升区】--强势畜锐'),COLORMAGENTA,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,DD+KJ/3,'【关注区】--逢低买入'),COLORRED,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,DD+KJ/10,'【低吸区】--大胆买入'),COLORRED,FONTSIZE20,COLOR004080;



DRAWNUMBER(ISLASTBAR,GD,GD,0,COLORWHITE),FONTSIZE30,ALIGN0,VALIGN1;
DRAWNUMBER(ISLASTBAR,DD,DD,0,COLORWHITE),FONTSIZE30,ALIGN0,VALIGN1;

 

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

博易技术人员: N:=120;
CURRBARSCOUNT:=DATACOUNT-BARPOS+1;
KT:=BARSLAST(CURRBARSCOUNT=N);
GD:=REFX(IF(ISLASTBAR=1,HHV(H,KT),0),DATACOUNT-BARPOS-1);//{高点}
DD:=REFX(IF(ISLASTBAR=1,LLV(L,KT),0),DATACOUNT-BARPOS-1);//{低点}
KJ:=GD-DD;//{高低点差值=分区高度}
GD4:=IF(CURRBARSCOUNT<=N/30+16,GD,DRAWNULL);
高:=IF(CURRBARSCOUNT<=N/30+16,GD,DRAWNULL),COLORWHITE,COLOR00FFFF,PRECIS0;
低:=IF(CURRBARSCOUNT<=N/30+16,DD,DRAWNULL),COLORWHITE,COLORFFFF00,PRECIS0;


高区:IF(CURRBARSCOUNT<=N+16,GD,DRAWNULL),COLORWHITE,DASH,COLOR004080,PRECIS0;
低区:IF(CURRBARSCOUNT<=N+16,DD,DRAWNULL),COLORWHITE,DASH,COLOR004080,PRECIS0;


压力:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.809,DRAWNULL),COLORGREEN,COLOR00FF00,PRECIS0;
警示:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.618,DRAWNULL),COLOR00FFFF,PRECIS0;
突破:IF(CURRBARSCOUNT<=N/40+16,DD+KJ/2,DRAWNULL),COLORYELLOW,COLOR0000FF,PRECIS0;
强势: IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.382,DRAWNULL),COLORFF00FF,PRECIS0;
支撑:IF(CURRBARSCOUNT<=N/40+16,DD+KJ*0.191,DRAWNULL),COLORRED,COLOR00FFFF,PRECIS0;
低涨:IF(CURRBARSCOUNT<=N/40+16,(C/LLV(LOW,KT)-1)*100,DRAWNULL),COLORFF8000,COLOR0000FF,NODRAW,PRECIS0;
天数:BARSLAST(L=DD),COLORWHITE,NODRAW,PRECIS0;




//{STICKLINE1(CURRBARSCOUNT=N/30,GD,DD,0,0),COLORGREEN;
//STICKLINE1(CURRBARSCOUNT=1,GD,DD,0,0),COLORGREEN;}
STICKLINE(CURRBARSCOUNT<=N/30,支撑,支撑,14,0),COLORFF00FF;

STICKLINE(CURRBARSCOUNT<=N/30,强势,强势,14,0),COLORFF00FF;
STICKLINE(CURRBARSCOUNT<=N/30,突破,突破,14,0),COLORABABAB;
STICKLINE(CURRBARSCOUNT<=N/30,警示,警示,14,0),COLOR00FFFF;

STICKLINE(CURRBARSCOUNT<=N/30,压力,压力,14,0),COLOR00FFFF;



DRAWTEXT(CURRBARSCOUNT=N/40+16,高,'高位:809'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,压力,'压力:681'),COLORMAGENTA,FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,警示,'警示:500'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,强势,'强势:382'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,支撑,'支撑:191'),FONTSIZE20,ALIGN2,VALIGN1;
DRAWTEXT(CURRBARSCOUNT=N/40+16,低,'低位:000'),FONTSIZE20,ALIGN2,VALIGN1;


M:=BARSLAST(CURRBARSCOUNT=N);
平衡:=IF(CURRBARSCOUNT<=N,DD+KJ/2,DRAWNULL),COLORWHITE,POINTDOT,COLOR004080,PRECIS0;
CD:=CURRBARSCOUNT,NODRAW;
STICKLINE(CD=46,HHV(高区,60),LLV(低区,60),10,0),COLORBLACK,COLOR004080;
STICKLINE(CD=120,HHV(高区,60),LLV(低区,60),10,0),COLORBLUE,COLOR004080;
STICKLINE(CD=1,HHV(高区,60),LLV(低区,60),0.10,0),COLOR000000,COLOR004080;

DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.09,'【风险区】--高抛避险'),COLORGREEN,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.3,'【警示区】--逢高减仓'),COLORGREEN,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.45,'【突破区】--主力拉升'),COLORMAGENTA,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,GD-KJ*0.55,'【拉升区】--强势畜锐'),COLORMAGENTA,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,DD+KJ/3,'【关注区】--逢低买入'),COLORRED,FONTSIZE20,COLOR004080;
DRAWTEXT(CURRBARSCOUNT=N/4+46,DD+KJ/10,'【低吸区】--大胆买入'),COLORRED,FONTSIZE20,COLOR004080;



DRAWNUMBER(ISLASTBAR,GD,GD,0),COLORWHITE,FONTSIZE30,ALIGN0,VALIGN1;
DRAWNUMBER(ISLASTBAR,DD,DD,0),COLORWHITE,FONTSIZE30,ALIGN0,VALIGN1; 来源 程序化久久网

 

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

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

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

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


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

相关文章

    没有相关内容