超级布林
本指标用来分析主力做多或做空的心理状态!
{参数:N=26,N1=2,N2=31}
INPUT:N(26),N1(2),N2(31);
DRAWGBK(1,colorrgb(0,0,100),colorrgb(0,0,0),1);
wyy1:=WEEKDAY,LINETHICK0;
wWj:=' 星期';
wWjj:=IF(wyy1=5 ,wWj+'五',IF(wyy1=4 ,wWj+'四',
IF(wyy1=3 ,wWj+'三',IF(wyy1=2 ,wWj+'二',IF(wyy1=1 ,wWj+'1',wWj)))));
wyy2:=LMONTH;
wyy3:=LDAY;
wWw:=IF( BARSTATUS=2 ,' 农历 '+NUMTOSTR(wyy2,0)+'月 '+NUMTOSTR(wyy3,0)+'日',' ');
wWh:=IF( BARSTATUS=2 ,NUMTOSTR(date+19000000,0),' ' );
DRAWTEXTEX(1,1,120 ,30 ,' '+wWh+wWjj+wWw),LINETHICK3,ColorFFFF80;
a0:=BARSCOUNT(c);
a3:=SYSPARAM(3);
a2:=SYSPARAM(2);
a4:=SYSPARAM(4);
a5:=SYSPARAM(5);
nn0:=a3-a2;nn:=a0-a2;hh1:=(a4-a5)/8;
hh2:=hh1/4;
ll1:=llv(l,nn0);ll2:=ll1[a3];
y0:=a0>=a2;vv0:=if(y0=1 and SYSPARAM(1)>=a0,v,0);
c1:=if(BETWEEN(c,a4-0*hh1,a4-1*hh1),vv0,0);
c2:=if(BETWEEN(c,a4-1*hh1,a4-2*hh1),vv0,0);
c3:=if(BETWEEN(c,a4-2*hh1,a4-3*hh1),vv0,0);
c4:=if(BETWEEN(c,a4-3*hh1,a4-4*hh1),vv0,0);
c5:=if(BETWEEN(c,a4-4*hh1,a4-5*hh1),vv0,0);
c6:=if(BETWEEN(c,a4-5*hh1,a4-6*hh1),vv0,0);
c7:=if(BETWEEN(c,a4-6*hh1,a4-7*hh1),vv0,0);
c8:=if(BETWEEN(c,a4-7*hh1,a4-8*hh1),vv0,0);
c9:=if(BETWEEN(c,a4-8*hh1,a4-9*hh1),vv0,0);
c10:=if(BETWEEN(c,a4-9*hh1,a4-10*hh1),vv0,0);
v1:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c1,nn0),0),2)),LINETHICK;
v2:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c2,nn0),0),2));
v3:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c3,nn0),0),2));
v4:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c4,nn0),0),2));
v5:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c5,nn0),0),2));
v6:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c6,nn0),0),2));
v7:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c7,nn0),0),2));
v8:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c8,nn0),0),2));
v9:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c9,nn0),0),2));
v10:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c10,nn0),0),2));
av0:=max(v1,max(v2,max(v3,max(v4,max(v5,max(v6,max(v7,max(v8,max(v9,v10)))))))));
x1:=v1/av0>=nn/nn0 and nn>=0;
x2:=v2/av0>=nn/nn0 and nn>=0;
x3:=v3/av0>=nn/nn0 and nn>=0;
x4:=v4/av0>=nn/nn0 and nn>=0;
x5:=v5/av0>=nn/nn0 and nn>=0;
x6:=v6/av0>=nn/nn0 and nn>=0;
x7:=v7/av0>=nn/nn0 and nn>=0;
x8:=v8/av0>=nn/nn0 and nn>=0;
FILLRGN(v1/av0>=nn/nn0 and nn>=0,a4-0*hh1,a4-1*hh1+hh1*0.5),Color003CB7;
FILLRGN(v2/av0>=nn/nn0 and nn>=0,a4-1*hh1,a4-2*hh1+hh1*0.5),Color808000;
FILLRGN(v3/av0>=nn/nn0 and nn>=0,a4-2*hh1,a4-3*hh1+hh1*0.5),Color8B4D43;
FILLRGN(v4/av0>=nn/nn0 and nn>=0,a4-3*hh1,a4-4*hh1+hh1*0.5),Color1B3D70;
FILLRGN(v5/av0>=nn/nn0 and nn>=0,a4-4*hh1,a4-5*hh1+hh1*0.5),Color00AEAE;
FILLRGN(v6/av0>=nn/nn0 and nn>=0,a4-5*hh1,a4-6*hh1+hh1*0.5),color666666;
FILLRGN(v7/av0>=nn/nn0 and nn>=0,a4-6*hh1,a4-7*hh1+hh1*0.5),color666666;
FILLRGN(v8/av0>=nn/nn0 and nn>=0,a4-7*hh1,a4-8*hh1+hh1*0.5),color666666;
DRAWNUMBER(FILTER(refx(x1<ref(x1,1),6) and v1>0,10),a4,a4-0*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x2<ref(x2,1),6) and v2>0,10),(a4-1*hh1),a4-1*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x3<ref(x3,1),6) and v3>0,10),(a4-2.7*3*hh2),a4-2*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x4<ref(x4,1),6) and v4>0,10),(a4-12*hh2),a4-3*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x5<ref(x5,1),6) and v5>0,10),(a4-16*hh2),a4-4*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x6<ref(x6,1),6) and v6>0,10),(a4-20*hh2),a4-5*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x7<ref(x7,1),6) and v7>0,10),(a4-24*hh2),a4-6*hh1,2),COLOR00FF00;
DRAWNUMBER(FILTER(refx(x8<ref(x8,1) and v8>0,5),10),ll2+1*4*hh2,a4-7*hh1,2),COLOR00FF00;
HH:=DYNAINFO(39);
DD:=FINANCE( 1);
SS:=FINANCE( 7);
FF:=FINANCE(18);
GG:=FINANCE(33);
zz:=FINANCE(53);
JJ:=FINANCE(40);
MM:=JJ/SS;
TH:=DYNAINFO(39);
换手率:=100*v/capital,colorfffFff;
RH:=H-L;
R:=DYNAINFO(13)*100;
DRAWTEXTEX(1,1,20,840,'当日振幅:'+NUMTOSTR(R,2)+'% '+NUMTOSTR(RH,2)+'元 '+' 当前换手率:'+NUMTOSTR(换手率,2)+'% '),ColorFFFFFF;
var100:='所属板块:';
if inblock('电力')=1 then var100:=var100+' 电力';
if inblock('电脑')=1 then var100:=var100+' 电脑';
if inblock('电器')=1 then var100:=var100+' 电器';
if inblock('电子信息')=1 then var100:=var100+' 电子信息';
if inblock('房地产')=1 then var100:=var100+' 房地产';
if inblock('纺织服装')=1 then var100:=var100+' 纺织服装';
if inblock('钢铁')=1 then var100:=var100+' 钢铁';
if inblock('工程建筑')=1 then var100:=var100+' 工程建筑';
if inblock('供水供气')=1 then var100:=var100+' 供水供气';
if inblock('化工')=1 then var100:=var100+' 化工';
if inblock('化纤')=1 then var100:=var100+' 化纤';
if inblock('机械')=1 then var100:=var100+' 机械';
if inblock('建材')=1 then var100:=var100+' 建材';
if inblock('交通工具')=1 then var100:=var100+' 交通工具';
if inblock('交通设施')=1 then var100:=var100+' 交通设施';
if inblock('教育传媒')=1 then var100:=var100+' 教育传媒';
if inblock('金融')=1 then var100:=var100+' 金融';
if inblock('旅游酒店')=1 then var100:=var100+' 旅游酒店';
if inblock('煤炭石油')=1 then var100:=var100+' 煤炭石油';
if inblock('酿酒食品')=1 then var100:=var100+' 酿酒食品';
if inblock('农林牧渔')=1 then var100:=var100+' 农林牧渔';
if inblock('其他行业')=1 then var100:=var100+' 其他行业';
if inblock('汽车')=1 then var100:=var100+' 汽车';
if inblock('汽配')=1 then var100:=var100+' 汽配';
if inblock('商业连锁')=1 then var100:=var100+' 商业连锁';
if inblock('石化')=1 then var100:=var100+' 石化';
if inblock('通信')=1 then var100:=var100+' 通信';
if inblock('外贸')=1 then var100:=var100+' 外贸';
if inblock('医药')=1 then var100:=var100+' 医药';
if inblock('仪电仪表')=1 then var100:=var100+' 仪电仪表';
if inblock('有色金属')=1 then var100:=var100+' 有色金属';
if inblock('运输物流')=1 then var100:=var100+' 运输物流';
if inblock('造纸印刷')=1 then var100:=var100+' 造纸印刷';
if inblock('安徽')=1 then var100:=var100+' 安徽';
if inblock('北京')=1 then var100:=var100+' 北京';
if inblock('福建')=1 then var100:=var100+' 福建';
if inblock('甘肃')=1 then var100:=var100+' 甘肃';
if inblock('广东')=1 then var100:=var100+' 广东';
if inblock('广西')=1 then var100:=var100+' 广西';
if inblock('贵州')=1 then var100:=var100+' 贵州';
if inblock('海南')=1 then var100:=var100+' 海南';
if inblock('河北')=1 then var100:=var100+' 河北';
if inblock('河南')=1 then var100:=var100+' 河南';
if inblock('黑龙江')=1 then var100:=var100+' 黑龙江';
if inblock('湖北')=1 then var100:=var100+' 湖北';
if inblock('湖南')=1 then var100:=var100+' 湖南';
if inblock('吉林')=1 then var100:=var100+' 吉林';
if inblock('江苏')=1 then var100:=var100+' 江苏';
if inblock('江西')=1 then var100:=var100+' 江西';
if inblock('辽宁')=1 then var100:=var100+' 辽宁';
if inblock('内蒙古')=1 then var100:=var100+' 内蒙古';
if inblock('宁夏')=1 then var100:=var100+' 宁夏';
if inblock('青海')=1 then var100:=var100+' 青海';
if inblock('山东')=1 then var100:=var100+' 山东';
if inblock('山西')=1 then var100:=var100+' 山西';
if inblock('陕西')=1 then var100:=var100+' 陕西 |