超級布林(藝術美主圖指標公式) 用來分析主力做多或做空的心理狀態[其他軟件公式]
相關標簽:
?
超級布林
本指標用來分析主力做多或做空的心理狀態!
?
?
原理解析:
源碼:
?
?
{參數: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+' 陜西';
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('3G')=1 then var100:=var100+' 3G';
if inblock('H股')=1 then var100:=var100+' H股';
if inblock('QFII持股')=1 then var100:=var100+' QFII持股';
if inblock('ST')=1 then var100:=var100+' ST';
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+' 股權投資';
DRAWTEXTEX(1,1,20,960,var100),color00ffff;
DRAWTEXTEX(1,1,20,900,'總股本:'+NUMTOSTR(DD,0)+'萬股' +' 流通A股:'+NUMTOSTR(SS,0)+'萬股'+' 市盈率:'+NUMTOSTR(HH,2)+'%'+'每股收益:'+NUMTOSTR(GG,3)),COLORbbffff;
天:MA(C,n)+3*STD(C,n),COLOR66bbff;
地:MA(C,n)-3*STD(C,n),COLORGREEN;
a:=(c+FORCAST(c,n1))/2;
心:FORCAST(FORCAST(a,n2),10),CIRCLEDOT,COLORWHITE;
紅:IF(a<心,a,心),LINETHICK2,COLORff00ff;
蘭:IF(a>心,a,心),LINETHICK2,COLORff8800;
var9Q:=c= hhv(c,4)and (ref(c,1)>=ref(c,2) or ref(c,1)>=ref(c,3)) or ref(c,1)=hhv(c,4) and close>=ref(c,2) or ref(c,2)=hhv(c,4) and ref(c,3)=llv(c,4) and c>=ref(c,1) or ref(c,3)=hhv(c,4) and c>=ref(c,1) and c>=ref(c,2);
varaQ:=c=hhv(c,4) and ref(c,1)=llv(c,4);
varbQ:=c=llv(c,4) and (ref(c,1)<ref(c,2) or ref(c,1)<ref(c,3)) or ref(c,1)=llv(c,4) and c<ref(c,2) or ref(c,2)=llv(c,4) and ref(c,1)<>hhv(c,4) and c<ref(c,1) or ref(c,3)=llv(c,4) and c<ref(c,1) and c<ref(c,2);
varcQ:=ref(c,1)=llv(c,4) and c>=ref(c,2) or ref(c,2)=llv(c,4) and ref(c,1)<=ref(c,3) and ref(c,2)<ref(c,4) and c>=ref(c,1);
vardQ:=ref(c,1)=hhv(c,4) and c<ref(c,2) or (ref(c,2)=hhv(c,4) and ref(c,1)>ref(c,3) or ref(c,3)=hhv(c,4) and ref(c,1)>ref(c,2)) and ref(c,2)>=ref(c,4) and c<ref(c,1);
STICKLINE(CLOSE>OPEN,OPEN,LOW,0.5,0 ),COLOR0000FF;
STICKLINE(CLOSE>OPEN,CLOSE,HIGH,0.5 ,0 ),COLOR0000FF;
STICKLINE(OPEN>=CLOSE,CLOSE,LOW,0.5 ,0 ),COLOR00FF00;
STICKLINE(OPEN>=CLOSE,OPEN,HIGH,0.5 ,0 ),COLOR00FF00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,7,0 ),COLORff7700;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,6,0 ),COLORff9900;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,5,0 ),COLORffbb00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,4,0 ),COLORffcc00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,3,0 ),COLORffdd00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,2,0 ),COLORffee00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1,0 ),COLORffFF00;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,7,0) ,COLOR000055;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,6,0) ,COLOR000066;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,5,0) ,COLOR000077;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,4,0) ,COLOR000099;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,3,0) ,COLOR0000bb;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,2,0) ,COLOR0000dd;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1,0) ,COLOR0000ff;
紅:=var9Q;
stickline(var9Q,c,(o+c)/2,7,0),color000055;
stickline(var9Q,c,(o+c)/2,6,0),color000066;
stickline(var9Q,c,(o+c)/2,5,0),color000077;
stickline(var9Q,c,(o+c)/2,4,0),color000099;
stickline(var9Q,c,(o+c)/2,3,0),color0000bb;
stickline(var9Q,c,(o+c)/2,2,0),color0000dd;
stickline(var9Q,c,(o+c)/2,1,0),color0000ff;
粉:=varaQ;
stickline(varaQ,c,(o+c)/2,7,0),colorff11ff;
stickline(varaQ,c,(o+c)/2,6,0),colorff33ff;
stickline(varaQ,c,(o+c)/2,5,0),colorff55ff;
stickline(varaQ,c,(o+c)/2,4,0),colorff77ff;
stickline(varaQ,c,(o+c)/2,3,0),colorff99ff;
stickline(varaQ,c,(o+c)/2,2,0),colorffbbff;
stickline(varaQ,c,(o+c)/2,1,0),colorffddff;
灰:=varbQ;
stickline(varbQ,c,(o+c)/2,7,0),color333333;
stickline(varbQ,c,(o+c)/2,6,0),color555555;
stickline(varbQ,c,(o+c)/2,5,0),color777777;
stickline(varbQ,c,(o+c)/2,4,0),color999999;
stickline(varbQ,c,(o+c)/2,3,0),colorbbbbbb;
stickline(varbQ,c,(o+c)/2,2,0),colordddddd;
stickline(varbQ,c,(o+c)/2,1,0),colorffffff;
綠:=varcQ;
stickline(varcQ,o,(o+c)/2,7,0),color003300;
stickline(varcQ,o,(o+c)/2,6,0),color005500;
stickline(varcQ,o,(o+c)/2,5,0),color007700;
stickline(varcQ,o,(o+c)/2,4,0),color009900;
stickline(varcQ,o,(o+c)/2,3,0),color00bb00;
stickline(varcQ,o,(o+c)/2,2,0),color00dd00;
stickline(varcQ,o,(o+c)/2,1,0),color00ff00;
藍:=vardQ;
stickline(vardQ,o,(o+c)/2,7,0),colorff1100;
stickline(vardQ,o,(o+c)/2,6,0),colorff3300;
stickline(vardQ,o,(o+c)/2,5,0),colorff5500;
stickline(vardQ,o,(o+c)/2,4,0),colorff7700;
stickline(vardQ,o,(o+c)/2,3,0),colorff9900;
stickline(vardQ,o,(o+c)/2,2,0),colorffbb00;
stickline(vardQ,o,(o+c)/2,1,0),colorffdd00;<!--++ plugin_code qcomic begin-->
{程序化交易 www.tumamayizhan.com }
?
公式導入教程: 【通達信公式源碼導入方法教程】 【同花順公式源碼導入方法教程】 【大智慧新一代公式源碼導入方法教程】
?
有思路,想編寫各種指標公式,交易模型,選股公式,還原公式的朋友
可聯系技術人員 QQ: 262069696 或微信:cxhjy888 進行 有償收費 編寫!(注:由于人數限制,QQ或微信請選擇方便的一個聯系我們就行,加好友時請簡單備注下您的需求,否則無法通過。謝謝您!)
(注:由于人數限制,QQ或微信請選擇方便的一個聯系我們就行,加好友時請簡單備注下您的需求,否則無法通過。謝謝您!)
相關文章
-
沒有相關內容