您现在的位置:  股票知识 > 股票指标 > BOLL指标 > 正文
南财搜索

中枢+均线+布林线指标股票公式

2013-10-08 16:34    股票知识   zhishi.southmoney.com
    

  中枢+均线+布林线

  要过年了,有些缠友还不会画中枢,现在提供一个本博飞狐的主图指标,大家在过年期间好好学习吧。本博主图所画中枢,基本上是缠讲62课之前所说的周期图中的中枢,需要悟多中枢公式组件(chzhshch.dll),安装到飞狐文件夹FMLDLL下,本博主图公式目前仅适用于飞狐系列软件。

  {缠终禅主图公式}

  if DATAPERIOD=0 then minbi:=“fbase.var2#min1”;

  if DATAPERIOD=1 then minbi:=“fbase.var2#min5”;

  if DATAPERIOD=2 then minbi:=“fbase.var2#min30”;

  if DATAPERIOD=3 then minbi:=“fbase.var2#min60”;

  if DATAPERIOD=4 then minbi:=“fbase.var2#day”;

  if DATAPERIOD=5 then minbi:=“fbase.var2#day”;

  if DATAPERIOD=6 then minbi:=“fbase.var2#week”;

  if DATAPERIOD=7 then minbi:=“fbase.var2#month”;

  if DATAPERIOD=8 then minbi:=“fbase.var2#year”;

  if DATAPERIOD=9 then minbi:=“fbase.var2#day”;

  if DATAPERIOD=10 then minbi:=“fbase.var2#min60”;

  var1:=“chzhshch@kxian”;

  var2:=“chzhshch@bi”;{处理笔关系}

  var3:=“chzhshch@tongji”(minbi);{同级别分解}

  zg:=“chzhshch@zg”(var3);//一定要先调用ZG

  zd:=“chzhshch@zd”(var3);

  pre:=2; //设置小数点位数

  if STKTYPE=0 then pre:=1;

  if STKTYPE=11 then pre:=3;

  drawline(var2=1,h,var2=-1,l,0),COLORWHITE,LINEDASH,LINETHICK1;

  drawline(var2=-1,l,var2=1,h,0),COLORWHITE,LINEDASH,LINETHICK1;

  drawline(var3=1,h,var3=-1,l,0),COLORYELLOW,LINEDASH,LINETHICK1;

  drawline(var3=-1,l,var3=1,h,0),COLORYELLOW,LINEDASH,LINETHICK1;

  //以框的形式画中枢

  stickline(zg》zd and zg《》ref(zg,1),zg,zd,2,0),COLORMAGENTA ,LINETHICK2;

  stickline(zg》zd and zg《》refx(zg,1),zg,zd,2,0),COLORMAGENTA ,LINETHICK2;

  drawline(zg》zd and zg《》ref(zg,1),zg,zg》zd and zg《》refx(zg,1),zg,0),COLORMAGENTA ,LINETHICK2;

  drawline(zg》zd and zd《》ref(zd,1),zd,zg》zd and zd《》refx(zd,1),zd,0),COLORMAGENTA ,LINETHICK2;

  if DATAPERIOD《=1 then

  begin var2:=var3;{处理段1分钟的关系}

  end;

  pre:=2; {设置小数点位数}

  if STKTYPE=0 then pre:=1;

  if STKTYPE=11 then pre:=3;

  a1:=barslast(var2《》0);

  a2:=ref(var2,a1);

  aa1:=ref(a1+1,1);

  aa2:=ref(a2,1);

  a3:=if (aa2》0,l-ref(h,aa1),h-ref(l,aa1)),linethick0;{计算点位差}

  //显示点位

  drawnumber(var2= 1,h,h,pre),pxup99,color3300ff,align0;

  drawnumber(var2=-1,l,l,pre),pxdn99,colorffff00,align0;

  //显示力度

  drawtext (var2= 1,h,‘+’ ),pxup40,colormagenta,align2;

  drawnumber(var2= 1,h,a3,pre),pxup40,colormagenta,align1;

  drawnumber(var2=-1,l,a3,pre),pxdn40,colorgreen ,align0;

  //显示周期数

  drawtext (var2= 1,h,‘T’ ),pxup70,coloryellow,align1;

  drawnumber(var2= 1,h,aa1,0 ),pxup70,coloryellow,align2;

  drawtext (var2=-1,l,‘T’ ),pxdn70,coloryellow,align1;

  drawnumber(var2=-1,l,aa1,0 ),pxdn70,coloryellow,align2;

  stickline(DATAPERIOD=6 and c/ref(c,1)》=1.097,o,c,6,1),colormagenta;

  //显示最后没完成的点位

  aa9:=hhv(h,a1);

  aa11:=llv(l,a1);

  drawnumber( islastbar and a2= 1,aa11,aa11,pre),pxdn99,colorffff00,align0;

  drawnumber( islastbar and a2=-1, aa9, aa9,pre),pxup99,color3300ff,align0;

  //显示最后没完成的力度

  drawtext( islastbar and a2=-1, aa9,‘+’ ),pxup40,colormagenta,align2;

  drawnumber( islastbar and a2=-1, aa9,a3,pre),pxup40,colormagenta,align1;

  drawnumber( islastbar and a2=1, aa11,a3,pre),pxdn40,colorgreen ,align0;

  //显示最后没完成的周期

  drawtext( islastbar and a2=-1, aa9, ‘T’),pxup70,coloryellow,align1;

  drawnumber(islastbar and a2=-1, aa9,aa1,0),pxup70,coloryellow,align2;

  drawtext( islastbar and a2= 1, aa11, ‘T’),pxdn70,coloryellow,align1;

  drawnumber(islastbar and a2= 1, aa11,aa1,0),pxdn70,coloryellow,align2;

  涟:EMA(CLOSE,5),COLORYELLOW,LINETHICK1;

  漪:EMA(CLOSE,10),COLORGREEN,LINETHICK1;

  波:EMA(CLOSE,30),COLORWHITE,LINETHICK2;

  浪:EMA(CLOSE,89),COLORRED,LINEDOT,LINETHICK1;

  涛:EMA(CLOSE,144),COLORMAGENTA,LINEDASHDOT,LINETHICK1;

  潮:MA(CLOSE,288),COLORCYAN,LINEDASHDOT,LINETHICK1;

  啸:MA(CLOSE,720),COLORWHITE,LINEDASHDOT,LINETHICK1;

  峰:波+3.5*STDP(CLOSE,30),COLORYELLOW,LINETHICK2;

  谷:波-3.5*STDP(CLOSE,30),COLORGREEN,LINETHICK2;

(股票知识网zhishi.southmoney.com)
    股票知识网声明:资讯来源于合作媒体及机构,属作者个人观点,仅供投资者参考,并不构成投资建议。投资者据此操作,风险自担。
商务进行时
股票知识学习
联盟广告

关于股票知识网 -版权声明 -诚聘英才 -广告服务 -网站地图 -
特此声明:广告商的言论与行为均与股票知识网无关
zhishi.southmoney.com
股票知识网 © 版权所有 闽ICP备09035581号