您现在的位置:程序化交易>> 股票公式>> 其他>> 其他软件公式>>正文内容

■新宝塔线■原码[其他软件公式]

相关标签:期货真正的宝塔线指标 、 mt4宝塔线指标下载 、 手机版宝塔线副图指标 、 通达信宝塔线指标源码 、 通达信布林宝塔线指标 、 宝塔线选股指标源码 、 宝塔线指标精解陈辉 、 宝塔线指标视频讲解 、 宝塔线主图指标公式 、

 

{■新宝塔线■-----原码}
//注意其中的两个未来不影响买卖;
DRAWGBK((CLOSE > 0),COLORRGB(0,0,88),COLORRGB(0,0,55),1);

线1:HHV(FORCAST(CLOSE,10),18)*1.01,colorE66878;
线2:HHV(FORCAST(CLOSE,10),14)*1.01,colorF0F000;
线3:HHV(FORCAST(CLOSE,10),10)*1.01,colorFFFF;
线4:HHV(FORCAST(CLOSE,10),6)*1.01,colorFF00;
线:FORCAST(CLOSE,10)*1.01,LINETHICK1,colorFF;
FILLRGN(线,线,线4),Color9DADBB;
FILLRGN(线4,线4,线3),Color167400;
FILLRGN(线3,线3,线2),Color007368;
FILLRGN(线2,线2,线1),Color0029B9;

BDDD:=C=LLV(C,6),LINETHICK0;
N20:=BARSLAST(BDDD);
低:IF(N20,REF(C,N20),REF(C,N20))*0.99,COLORRED,LINETHICK0;
启动:C>低 AND REF(C=低,1),COLOR00FF00,POINTDOT,LINETHICK0;
PARTLINE(低=ref(低,1),低),COLORRED,LINETHICK1;
{以下设置副图显示方式}
IF(C,C,C),COLORFF00FF,LINETHICK0;
DRAWTEXT(启动,L*0.98,'↑'),COLORRED, ALIGN0;
PARTLINE(低<REF(低,1),低),COLORBLACK;

VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),9,0),color000055;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),8,0),color000066;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),7,0),color000077;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),6,0),color000088;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),5,0),color000099;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),4,0),color0000aa;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),3,0),color0000bb;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),2,0),color0000cc;
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),1,0),color0000dd;
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),9,0),colorFF1100;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),8,0),colorFF2200;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),7,0),colorFF3300;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),6,0),colorFF4400;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),5,0),colorFF5500;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),4,0),colorFF6600;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),3,0),colorFF7700;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),2,0),colorFF8800;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),1,0),colorFF9900;
VAR19:=(REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1)) AND VAR1;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),9,0),COLOR225588;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),8,0),COLOR225588;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),7,0),COLOR226699;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),6,0),COLOR3377aa;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),5,0),COLOR3388bb;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),4,0),COLOR4499cc;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3,0),COLOR44aadd;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2,0),COLOR55bbee;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),1,0),COLOR66ccff;
VAR1A:=(REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1)) AND VARD;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),9,0),COLOR006600;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),8,0),COLOR007700;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),7,0),COLOR008800;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),6,0),COLOR009900;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),5,0),COLOR00aa00;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),4,0),COLOR00BB00;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3,0),COLOR00CC00;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),2,0),COLOR00DD00;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),1,0),COLOR00EE00;

yyzq:=(sysparam(3)-sysparam(2))/1.6;
FILL:=barscount(c)>SYSPARAM(2) and barscount(c)<if(sysparam(3)-sysparam(2)>10,SYSPARAM(2)+INTPART(yyzq/2),10);
pich:=refx(hhv(sysparam(4),yyzq),yyzq);
picl:=refx(llv(sysparam(5),yyzq),yyzq);
fillrgn(ref(fill,1) and refx(fill,1),refx(pich,yyzq),refx(picl,yyzq)),Color3A630E;

ZHH:=H;
ZGF1 := ZHH/1.0809;ZGF2 := ZHH/1.1618;
ZGF3 := ZHH/1.0809/1.1618; ZGF4 := ZHH/1.1618/1.1618;
DRAWTEXTEX(sysparam(3)=BARPOS,0,2,106,' 【第一回调位】:'+NUMTOSTR(ZGF1[SYSPARAM(1)],2)+'-'+NUMTOSTR(ZGF2[SYSPARAM(1)],2)+''),LINETHICK2,ColorFF00FF;
DRAWTEXTEX(sysparam(3)=BARPOS,0,2,124,' 【第二回调位】:'+NUMTOSTR(ZGF3[SYSPARAM(1)],2)+'-'+NUMTOSTR(ZGF4[SYSPARAM(1)],2)+''),LINETHICK2,ColorFF00FF;
ZLL:=L;
ZGFB1:=ZLL*1.0809; ZGFB2 := ZLL*1.1618; ZGFB3 := ZLL*1.0809*1.1618;ZGFB4 := ZLL*1.1618*1.1618;
DRAWTEXTEX(sysparam(3)=BARPOS,0,2,148,' 【第一压力位】:'+NUMTOSTR(ZGFB1[SYSPARAM(1)],2)+''+'--'+NUMTOSTR(ZGFB2[SYSPARAM(1)],2)+''),LINETHICK2,ColorFF00FF;
DRAWTEXTEX(sysparam(3)=BARPOS,0,2,166,' 【第二压力位】:'+NUMTOSTR(ZGFB3[SYSPARAM(1)],2)+''+'--'+NUMTOSTR(ZGFB4[SYSPARAM(1)],2)+''),LINETHICK2,ColorFF00FF;
DRAWTEXTEX(sysparam(3)=BARPOS,0,2,190,' 【起点价:'+NUMTOSTR(ZLL[SYSPARAM(1)],2)+'】'),ColorFF00FF;
DRAWTEXTEX(sysparam(3)=BARPOS,0,80,190,' 【回点价:'+NUMTOSTR(ZHH[SYSPARAM(1)],2)+'】'),ColorFF00FF;

DRAWTEXTex(1,10,10,15,'■所属板块:'+BlKNAME),Color00FF00;
DRAWTEXTex(1,0,23,30,STKLABEL+' '+STKNAME),LINETHICK1,ColorFFFFFC;
RH:=H-L;
R:=DYNAINFO(14)*100;
DRAWTEXTEX(1,0,10,45,'日高低差:'+NUMTOSTR(RH,2)+'元'),COLORWHITE;
金叉:=barslast(FILTER(CROSS("KD.K","KD.D") and "KD.D"<30,13));
主力吸筹区:=if(金叉>0 and 金叉<61,金叉,0);
DRAWTEXTex(1,0,10,60,'主力建仓天数:'+NUMTOSTR(主力吸筹区,0)+'天'),ColorFFFFFC,LINETHICK1;

MA30:=EMA(CLOSE,30);
MA60:=EMA(CLOSE,60);
MA125:=EMA(CLOSE,125);
MA250:=EMA(CLOSE,250);
A1:=MA30[SYSPARAM(1)];
RA1:=MA30[SYSPARAM(1)-1];
jt1:=IF(A1>RA1,'↑','↓');
SZ1:='\n\n\n \n\n\n\n\n\n\n\n \n\n\n\n\n\n\n\nMA30: '+NUMTOSTR(MA30[SYSPARAM(1)],2)+jt1;
DRAWTEXT(BARPOS=SYSPARAM(2),CLOSE,SZ1),align4,COLORGREEN;
A2:=MA60[SYSPARAM(1)];
RA2:=MA60[SYSPARAM(1)-1];
jt2:=IF(A2>RA2,'↑','↓');
SZ2:='\n\n\n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nMA60: '+NUMTOSTR(MA60[SYSPARAM(1)],2)+jt2;
DRAWTEXT(BARPOS=SYSPARAM(2),CLOSE,SZ2),align4,COLORGREEN;
A3:=MA125[SYSPARAM(1)];
RA3:=MA125[SYSPARAM(1)-1];
jt3:=IF(A3>RA3,'↑','↓');
SZ3:='\n\n\n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nMA125:'+NUMTOSTR(MA125[SYSPARAM(1)],2)+jt3;
DRAWTEXT(BARPOS=SYSPARAM(2),CLOSE,SZ3),align4,COLORGREEN;
A4:=MA250[SYSPARAM(1)];
RA4:=MA250[SYSPARAM(1)-1];
jt4:=IF(A4>RA4,'↑','↓');
SZ4:='\n\n\n \n\n\n\n \n\n\n\n\n\n\n\n\n\n\n\n\n\n \nMA250:'+NUMTOSTR(MA250[SYSPARAM(1)],2)+jt4;
DRAWTEXT(BARPOS=SYSPARAM(2),CLOSE,SZ4),align4,COLORGREEN;

{换手100%}
svol:=INTPART(SUM(V,0)/CAPITAL);
tj0:=svol>REF(svol,1) or BARSSINCE(CLOSE)=0;
S1:=BARSLAST(tj0)+1,PRECISION,COLORWHITE;//时间1
tj2:=S1<ref(S1,1);//取点
S2:=if(tj2,ref(S1,1)+1,S1),PRECISION,COLORMAGENTA;//时间2
S3:=sum(tj2,0),COLORMAGENTA;
阶段总额(万元):=SUM(AMOUNT/10000,S2)*100,PRECISION,LINETHICK,Color008BFA;//换手100%成交额
阶段总量(手):=SUM(V,S2)*100,PRECISION,LINETHICK,COLORCYAN;//换手100%成交量
阶段成本(元):=(阶段总额(万元)/(阶段总量(手)/100)),LINETHICK,PRECISION2,COLORRED;
DRAWTEXTex(1,0,10,75,'■阶段平均成本:'+NUMTOSTR(阶段成本(元)[SYSPARAM(1)],2)+'(元)'),align4,COLORCYAN;
Aa3:=SUMBARS(VOL,CAPITAL);
换手成本:=IF(CAPITAL>0,SUM(AMOUNT,Aa3)/SUM(VOL,Aa3)/100,EMA(CLOSE,120));{100%换手平均成本线};
DRAWTEXTEX(1,0,10,90,'换手成本:'),COLORYELLOW;
DRAWTEXTEX(1,0,70,90,NUMTOSTR(换手成本,2)),COLORYELLOW;
DRAWTEXT(BARPOS=SYSPARAM(2),HIGH,'山水先生推荐//■新宝塔线■//(飞狐源码)'
)align4,COLORYELLOW;
hh:=SYSPARAM(4);ll:=SYSPARAM(5);
x:=ll-(hh-ll+MINDIFF)/5;
y:=HHV(VOL,SYSPARAM(3)-SYSPARAM(2)+1);
yvb:=y[SYSPARAM(3)]/(ll-x+MINDIFF);
z:=VOL/yvb+x;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,9,0) ,colorAA;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,8,0) ,color11BB;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,7,0) ,color22CC;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,6,0) ,color33DD;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,5,0) ,color44EE;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,4,0) ,color55FF;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,2.2,0) ,color66FF;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,1.5,0) ,color77FF;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,9,0),colorAA00;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,8,0),colorBB11;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,7,0),colorCC22;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,6,0),colorDD33;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,5,0),colorEE44;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,4,0),colorFF55;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,2.5,0),colorFF66;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,1.5,0),colorFF77;

 

公式导入教程: 【通达信公式源码导入方法教程】 【同花顺公式源码导入方法教程】 【大智慧新一代公式源码导入方法教程

 

 

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

可联系技术人员 QQ: 262069696  点击在线交流或微信:cxhjy888 进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)

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

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

 


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

相关文章

    没有相关内容