公式指标平台 股票指标公式源码分享 登录 注册
公式指标平台
未来函数检测
首 页 金钻指标 通达信公式 大智慧公式 同花顺公式 文华财经公式 操盘手公式 东财通公式 飞狐公式 其他公式 公式解答 股票软件 股票池
当前位置:→ 公式指标平台 > 通达信公式 > 正文 → 正文

七剑下天山(大智慧、飞狐、通达信)

发布时间:2010/1/5 7:42:25  浏览次数:

 

C/C++ www.gszb.com 股票公式指标网提供 Code复制内容到剪贴板
  1. 通达信版源码:   
  2.                               七剑下天山   
  3.   
  4.   
  5.                               E1:=BARSCOUNT(C);   
  6.                               AH:=HHV(H,200);   
  7.                               AL:=LLV(L,200);   
  8.                               B0:=(AH-AL)/40;   
  9.                               KB1:=H+B0;   
  10.                               KB2:=L-B0;   
  11.                               STICKLINE((E1+0)/34=FLOOR((E1+0)/34),KB2,KB2-3*B0,1,0),COLORYELLOW,LINETHICK3;   
  12.                               DRAWTEXT((E1+0)/34=FLOOR((E1+0)/34),KB2-2*B0,'时间窗'),COLORWHITE;   
  13.                               {STICKLINE((OPEN >=    
  14.                               CLOSE),CLOSE,OPEN,5,0),COLORFF6C00;   
  15.                               STICKLINE((OPEN >=    
  16.                               CLOSE),CLOSE,OPEN,4,0),COLORFF7B00;   
  17.                               STICKLINE((OPEN >=    
  18.                               CLOSE),CLOSE,OPEN,3,0),COLORFF9C00;   
  19.                               STICKLINE((OPEN >=    
  20.                               CLOSE),CLOSE,OPEN,2,0),COLORFFBE00;   
  21.                               STICKLINE((OPEN >=    
  22.                               CLOSE),CLOSE,OPEN,2.5,0),COLORFFCC00;   
  23.                               STICKLINE((OPEN >=    
  24.                               CLOSE),CLOSE,OPEN,1.5,0),COLORFFFF00;   
  25.                               STICKLINE((CLOSE >=    
  26.                               OPEN),CLOSE,OPEN,6,0),COLOR070084;   
  27.                               STICKLINE((CLOSE >=    
  28.                               OPEN),CLOSE,OPEN,5,0),COLOR0000A3;   
  29.                               STICKLINE((CLOSE >=    
  30.                               OPEN),CLOSE,OPEN,4,0),COLOR0000B7;   
  31.                               STICKLINE((CLOSE >=    
  32.                               OPEN),CLOSE,OPEN,3,0),COLOR0000CD;   
  33.                               STICKLINE((CLOSE >=    
  34.                               OPEN),CLOSE,OPEN,2,0),COLOR0000E9;   
  35.                               STICKLINE((CLOSE >=    
  36.                               OPEN),CLOSE,OPEN,2,0),COLOR0754E9;   
  37.                               STICKLINE((CLOSE >=    
  38.                               OPEN),CLOSE,OPEN,1.5,0),COLOR076EF3;   
  39.                               STICKLINE((CLOSE >=    
  40.                               OPEN),CLOSE,OPEN,1,0),COLOR077BF3;   
  41.                               STICKLINE((CLOSE >    
  42.                               OPEN),OPEN,LOW,1,0),COLOR0726CA;   
  43.                               STICKLINE((CLOSE >    
  44.                               OPEN),CLOSE,HIGH,1,0),COLOR0726CA;   
  45.                               STICKLINE((OPEN >    
  46.                               CLOSE),CLOSE,LOW,1,0),COLORDE9100;   
  47.                               STICKLINE((OPEN >    
  48.                               CLOSE),OPEN,HIGH,1,0),COLORDE9100;}   
  49.                               卖出线:=98;   
  50.                               阶段卖:=96;   
  51.                               趋势4:=3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)-2*SMA   
  52.                               (SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1);   
  53.                               底部:=10;   
  54.                               买入信号RAWICON(CROSS(趋势4,底部),LOW,1);   
  55.                               卖出RAWICON(CROSS(卖出线,趋势4),HIGH,2);   
  56.                               顶压:HHV(MA(H,11),50),COLORFF9900,LINETHICK3;   
  57.                               短压:HHV(MA(H,11),15),COLOR0066FF,LINETHICK3;   
  58.                               XL1:=LLV(MA(H,11),1);   
  59.                               趋势3:IF(XL1>=短压,短压,XL1),COLORRED,LINETHICK2;   
  60.                               K1:=BACKSET(趋势3<REF(趋势3,1),2);   
  61.                               IF(K1,趋势3,DRAWNULL),COLOR00CC33,LINETHICK2;   
  62.   
  63.                               RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;   
  64.                               KK1:=REF(RSV,1);KK2:=REF(RSV,2);KA:=RSV;KK3:=REF(RSV,3);KK4:=REF(RSV,4);KK5:=REF(RSV,5);   
  65.                               KK80:=3*80-(POW(2/3,1)*KK1+POW(2/3,2)*KK2+POW(2/3,3)*KK3+POW(2/3,4)*KK4+3*POW(2/3,5)*KK5);   
  66.                               KKK80:=SMA((KK80*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  67.                               交叉:=3*SMA(SMA(KA,3,1),3,1)-(POW(2/3,1)*KK1+POW(2/3,2)*KK2+POW(2/3,3)*KK3+POW(2/3,4)*KK4+3*POW(2/3,5)*KK5);   
  68.                               K转折:=3*SMA(KA,3,1)-(POW(2/3,1)*KK1+POW(2/3,2)*KK2+POW(2/3,3)*KK3+POW(2/3,4)*KK4+3*POW(2/3,5)*KK5);   
  69.                               K转折价0:=SMA((K转折*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  70.                               日交叉0:=SMA((交叉*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  71.                               DRAWTEXT(K转折价0>=KKK80 AND    
  72.                               K转折价0>=日交叉0,日交叉0,'◆'),COLORFF00FF;   
  73.                               趋势:=    
  74.                               3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)    
  75.   
  76.                               -2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1),   
  77.                               COLORYELLOW,LINETHICK2;    
  78.                               警戒:=趋势<=5 ;    
  79.                               D1:=C/L>1.05 AND COUNT(警戒,3)>=1 AND    
  80.                               C/REF(C,1)>1.01;    
  81.                               DRAWTEXT(D1>0,L,'★长生剑'),COLOR00FF00;   
  82.                               趋势1:=    
  83.                               MA(3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)-2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1),5);    
  84.   
  85.                               买入1:= C/O>1.04 AND COUNT(趋势1<10,3)>=1;    
  86.                               D2:=(买入1);    
  87.                               DRAWTEXT(D2>0,L,'☆孔雀翎'),COLORFF00FF;   
  88.                               M1:=(CLOSE-MA(CLOSE,30))/STD(CLOSE,15)*100;    
  89.                               K:=SMA(M1,3,1);    
  90.                               D:=SMA(K,3,1);    
  91.                               J:=3*K-2*D;    
  92.                               DD:=M1<-300;    
  93.                               DA:=C/O>1.04 AND COUNT(M1<-300,3)>=1;   
  94.                               D3:=DA;    
  95.                               DRAWTEXT(D3>0,L,'★碧玉刀'),COLOR006EFF;   
  96.                               个股:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;    
  97.                               D4:=COUNT(个股<-8,3)>=1 AND ( C/L>1.05 ) ;    
  98.                               DRAWTEXT(D4>0,L,'◎多情环'),COLORRED;   
  99.                               LCA:=REF(CLOSE,1);    
  100.                               E:=-100*(HHV(HIGH,84)-CLOSE)/(HHV(HIGH,84)-LLV(LOW,84));    
  101.   
  102.                               底:=(( E<-98)*2000);    
  103.                               D5:=( C/L>1.04 AND C>REF(C,1)) AND    
  104. UNT(底,2)>=1;   
  105.                               DRAWTEXT(D5>0,L,'Ψ离别钩'),COLOR0090E0;   
  106.                               DIFFA:=(EMA(CLOSE,12) - EMA(CLOSE,26))*100+50;   
  107.                               DC:=C/L>1.05 AND DIFFA<40;   
  108.                               D6 :=FILTER(DC,5);   
  109.                               DRAWTEXT(D6>0,L,'↑霸王枪'),COLOR00FF00;   
  110.                               BB1:=LLV(LOW,5)=LLV(LOW,45) AND    
  111.                               CLOSE>=OPEN*1.035 ;    
  112.                               BB2:=CLOSE>(REF(HIGH,1)+REF(LOW,1))/2;    
  113.                               BB3:=(CLOSE-OPEN)/OPEN*100;    
  114.                               BB4:=REF(CLOSE,1);    
  115.                               BB5:=SMA(MAX(CLOSE-BB4,0),6,1)/SMA(ABS(CLOSE-BB4),6,1)*100;    
  116.   
  117.                               BB6:=COUNT(BB5<20,20)>=1;    
  118.                               BB108:=BB3>9 AND BB6;    
  119.                               BB7:=(CLOSE-OPEN)/OPEN*100;    
  120.                               BB8:=REF(CLOSE,1);    
  121.                               BB9:=SMA(MAX(CLOSE-BB8,0),6,1)/SMA(ABS(CLOSE-BB8),6,1)*100;    
  122.   
  123.                               BB10:=COUNT(BB9<20,20)>=1;    
  124.                               BB109:=BB7>9 AND BB10;   
  125.                               DRAWTEXT(BB108 OR BB109>0,L,'★拳头'),COLORWHITE;   

 

C/C++ www.gszb.com 股票公式指标网提供 Code复制内容到剪贴板
  1.               大智慧,飞狐版源码:   
  2.                                 e1:=BARSCOUNT(c);   
  3.                                 ah:=hhv(h,200);   
  4.                                 al:=llv(l,200);   
  5.                                 b0:=(ah-al)/40;   
  6.                                 kb1:=h+b0;   
  7.                                 kb2:=l-b0;   
  8.                                 stickline((e1+0)/34=FLOOR((e1+0)/34),kb2,kb2-3*b0,2,0),COLOryellow,LINETHICK3;   
  9.                                 drawtext((e1+0)/34=FLOOR((e1+0)/34),kb2-2*b0,'时间窗'),COLORwhite;   
  10.                                 STICKLINE((OPEN >=    
  11.                                 CLOSE),CLOSE,OPEN,5,0),colorFF6C00;   
  12.                                 STICKLINE((OPEN >=    
  13.                                 CLOSE),CLOSE,OPEN,4,0),colorFF7B00;   
  14.                                 STICKLINE((OPEN >=    
  15.                                 CLOSE),CLOSE,OPEN,3,0),colorFF9C00;   
  16.                                 STICKLINE((OPEN >=    
  17.                                 CLOSE),CLOSE,OPEN,2,0),colorFFBE00;   
  18.                                 STICKLINE((OPEN >=    
  19.                                 CLOSE),CLOSE,OPEN,2.5,0),colorFFCC00;   
  20.                                 STICKLINE((OPEN >=    
  21.                                 CLOSE),CLOSE,OPEN,1.5,0),colorFFFF00;   
  22.                                 STICKLINE((CLOSE >=    
  23.                                 OPEN),CLOSE,OPEN,6,0),color070084;   
  24.                                 STICKLINE((CLOSE >=    
  25.                                 OPEN),CLOSE,OPEN,5,0),color0000A3;   
  26.                                 STICKLINE((CLOSE >=    
  27.                                 OPEN),CLOSE,OPEN,4,0),color0000B7;   
  28.                                 STICKLINE((CLOSE >=    
  29.                                 OPEN),CLOSE,OPEN,3,0),color0000CD;   
  30.                                 STICKLINE((CLOSE >=    
  31.                                 OPEN),CLOSE,OPEN,2,0),color0000E9;   
  32.                                 STICKLINE((CLOSE >=    
  33.                                 OPEN),CLOSE,OPEN,2,0),color0754E9;   
  34.                                 STICKLINE((CLOSE >=    
  35.                                 OPEN),CLOSE,OPEN,1.5,0),color076EF3;   
  36.                                 STICKLINE((CLOSE >=    
  37.                                 OPEN),CLOSE,OPEN,1,0),color077BF3;   
  38.                                 STICKLINE((CLOSE >    
  39.                                 OPEN),OPEN,LOW,1,0),color0726CA;   
  40.                                 STICKLINE((CLOSE >    
  41.                                 OPEN),CLOSE,HIGH,1,0),color0726CA;   
  42.                                 STICKLINE((OPEN >    
  43.                                 CLOSE),CLOSE,LOW,1,0),colorDE9100;   
  44.                                 STICKLINE((OPEN >    
  45.                                 CLOSE),OPEN,HIGH,1,0),colorDE9100;   
  46.                                 卖出线:=98;   
  47.                                 阶段卖:=96;   
  48.                                 趋势4:=3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)-2*SMA   
  49.                                        
  50.                                 (SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1);   
  51.                                 底部:=10;   
  52.                                 买入信号:drawicon(CROSS(趋势4,底部),low,1);   
  53.                                 卖出:drawicon(cross(卖出线,趋势4),high,2);   
  54.                                 顶压:HHv(ma(h,11),50),Color00FF00,LINETHICK3;   
  55.                                 短压:HHv(ma(h,11),15),Color0090E0,LINETHICK2;   
  56.                                 XL1:=llv(ma(h,11),1);   
  57.                                 趋势3:IF(XL1>=短压,短压,XL1),Colorwhite,LINETHICK1;   
  58.                                 RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;   
  59.                                 Kk1:=ref(RSV,1);Kk2:=ref(RSV,2);ka:=rsv;Kk3:=ref(RSV,3);Kk4:=ref(RSV,4);kk5:=ref(rsv,5);   
  60.                                 kk80:=3*80-(pow(2/3,1)*kk1+pow(2/3,2)*kk2+pow(2/3,3)*kk3+pow(2/3,4)*kk4+3*pow(2/3,5)*kk5);   
  61.                                 kkk80:=sma((kk80*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  62.                                 交叉:=3*sma(sma(ka,3,1),3,1)-(pow(2/3,1)*kk1+pow(2/3,2)*kk2+pow(2/3,3)*kk3+pow(2/3,4)*kk4+3*pow(2/3,5)*kk5);   
  63.                                 k转折:=3*sma(ka,3,1)-(pow(2/3,1)*kk1+pow(2/3,2)*kk2+pow(2/3,3)*kk3+pow(2/3,4)*kk4+3*pow(2/3,5)*kk5);   
  64.                                 k转折价0:=sma((k转折*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  65.                                 日交叉0:=sma((交叉*(HHV(H,9)-LLV(L,9))/100)+LLV(L,9),3,1);   
  66.                                 DRAWTEXT(k转折价0>=kkk80 and    
  67.                                 k转折价0>=日交叉0,日交叉0,'●'),COLORff00ff;   
  68.                                 趋势:=    
  69.                                 3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)    
  70.   
  71.                                 -2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1),   
  72.                                 COLORYELLOW,linethick2;    
  73.                                 警戒:=趋势<=5 ;    
  74.                                 d1:=c/l>1.05 and count(警戒,3)>=1 and    
  75.                                 c/ref(c,1)>1.01;    
  76.                                 DRAWTEXT(d1>0,L,'★长生剑'),Color00FF00;   
  77.                                 趋势1:=    
  78.                                 MA(3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)-2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1),3,1),5);    
  79.   
  80.                                 买入1:= c/o>1.04 and count(趋势1<10,3)>=1;    
  81.                                 D2:=(买入1);    
  82.                                 DRAWTEXT(D2>0,L,'☆孔雀翎'),Colorff00FF;   
  83.                                 m1:=(CLOSE-MA(CLOSE,30))/STD(CLOSE,15)*100;    
  84.                                 K:=SMA(M1,3,1);    
  85.                                 D:=SMA(K,3,1);    
  86.                                 J:=3*K-2*D;    
  87.                                 dd:=m1<-300;    
  88.                                 DA:=c/o>1.04 and count(m1<-300,3)>=1;   
  89.                                 D3:=DA;    
  90.                                 DRAWTEXT(D3>0,L,'★碧玉刀'),Color006EFF;   
  91.                                 个股:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;    
  92.                                 D4:=count(个股<-8,3)>=1 and ( c/l>1.05 ) ;    
  93.                                 DRAWTEXT(D4>0,L,'◎多情环'),Colorred;   
  94.                                 LCa:=REF(CLOSE,1);    
  95.                                 E:=-100*(HHV(HIGH,84)-CLOSE)/(HHV(HIGH,84)-LLV(LOW,84));    
  96.   
  97.                                 底:=(( E<-98)*2000);    
  98.                                 D5:=( c/l>1.04 and c>ref(c,1)) and    
  99. count(底,2)>=1;   
  100.                                 DRAWTEXT(D5>0,L,'Ψ离别钩'),Color0090E0;   
  101.                                 DIFFA:=(EMA(CLOSE,12) - EMA(CLOSE,26))*100+50;   
  102.                                 Dc:=c/L>1.05 and DIFFa<40;   
  103.                                 d6 :=filter(Dc,5);   
  104.                                 DRAWTEXT(D6>0,L,'↑霸王枪'),Color00ff00;   
  105.                                 BB1:=LLV(LOW,5)=LLV(LOW,45) AND    
  106.                                 CLOSE>=OPEN*1.035 ;    
  107.                                 BB2:=CLOSE>(REF(HIGH,1)+REF(LOW,1))/2;    
  108.                                 BB3:=(CLOSE-OPEN)/OPEN*100;    
  109.                                 BB4:=REF(CLOSE,1);    
  110.                                 BB5:=SMA(MAX(CLOSE-BB4,0),6,1)/SMA(ABS(CLOSE-BB4),6,1)*100;    
  111.   
  112.                                 BB6:=COUNT(BB5<20,20)>=1;    
  113.                                 BB108:=BB3>9 AND BB6;    
  114.                                 BB7:=(CLOSE-OPEN)/OPEN*100;    
  115.                                 BB8:=REF(CLOSE,1);    
  116.                                 BB9:=SMA(MAX(CLOSE-BB8,0),6,1)/SMA(ABS(CLOSE-BB8),6,1)*100;    
  117.   
  118.                                 BB10:=COUNT(BB9<20,20)>=1;    
  119.                                 BB109:=BB7>9 AND BB10;   
  120.                                 DRAWTEXT(bb108 or bb109>0,L,'★拳头'),Colorwhite;   

资源下载链接   资源大小:3KB

关于我们 - 联系我们 - 广告合作 - 下载声明 - 网站帮助 - 友情链接 - 网站地图 - RSS订阅 - TOP
湘ICP备09016573号 增值电信业务经营ICP许可证:湘B2-20210269 湘公网安备43108102000039号
Copyright © GSZB.COM ,All Rights Reserved.
股票公式,股票指标,股票软件,股票知识