首页 > 选股公式 > 通达信公式 > 正文

通达信必胜剑法主图指标公式(选股公式/源码)

2020-09-16 06:27:25 来源:网络

最近看到很多股民说需要通达信公式里关于通达信必胜剑法主图指标公式,下面红股网整理一份《通达信必胜剑法主图指标公式(选股公式/源码)》,希望让您对通达信公式有所认识。

A:=5;

EC:=INBLOCK('沪深A股'),NODRAW;

FB:=IF(EC=1,IF(CAPITAL>=200000000,A-2,IF(CAPITAL<200000000 AND CAPITAL>20000000,A-1,A)),A-2);

FS:=IF(EC=1,IF(CAPITAL>=200000000,A-1,IF(CAPITAL<200000000 AND CAPITAL>20000000,A,A+1)),A-1);

LMK:=(LLV(L,REF(HHVBARS(H,14),1)+1))*(1+FB/100);

BJJ:=IF(CROSS(C,LMK),LMK,0);

YBN:=BARSLAST(BJJ>0 OR BARSCOUNT(C)=1);

HMK:=HHV(H,YBN+1)*(1-FS/100);

SJJ:=IF(CROSS(HMK,C),HMK,IF(REF(YBN,1)=0 AND REF(HMK,1)>C,O,0));

YSN:=BARSLAST(SJJ>0 OR BARSCOUNT(C)=1);

EX11:=HHV(BJJ>0,YSN+1);

REE:=IF(BARSCOUNT(C)=1,0,REF(EX11,1));

YBJ:=IF(EX11>REE,BJJ,0),LINETHICK1,COLOR0088FF;

YSJ:=IF(EX11<REE,SJJ,0),LINETHICK1,COLOR00FF00;

PE:=IF(EX11=0,LMK,-HMK),NODRAW;

NBJ:=YBJ; NSJ:=YSJ;

BAR:=HHV(NBJ>0,0); X0:=SUM(BAR,0);

BN:=BARSLAST(NBJ>0);

SN:=BARSLAST(NSJ>0);

EX10:=HHV(NBJ,SN+1);

RE:=IF(BARSCOUNT(C)=1,0,REF(EX10,1));

BBJ:=IF(EX10>RE,NBJ,0); SSJ:=IF(EX10<RE,NSJ,0);

RBJ:=REF(BBJ,BN);

BSYL:=100*(IF(SSJ=0,C,SSJ)*0.997/RBJ/1.003-1);{佣金费率}

DRAWKLINE(HIGH,OPEN,LOW,CLOSE);

M0:MA(L,5),COLOR00FFFF;

预警:IF(BBJ>0,BBJ,IF(SSJ>0,SSJ,ABS(PE))),NODRAW;

多头盈利:BSYL,NODRAW;

BJ:=IF(BBJ>0,BBJ,DRAWNULL),NODRAW;

SJ:=IF(SSJ>0,SSJ,DRAWNULL),NODRAW;

DRAWICON(BJ>0,LLV(L,5),23);

DRAWICON(SJ>0 AND BSYL<0,H,2),DRAWABOVE;

DRAWICON(SJ>0 AND BSYL>0 AND BSYL<5,H,8),DRAWABOVE;

DRAWICON(SJ>0 AND BSYL>5,H,9),DRAWABOVE;

DRAWKLINE(HIGH,OPEN,LOW,CLOSE);

QQ:=1000000;

信号K%:=(X0>100)*100*SUM(SSJ>0,0)/X0,NODRAW;

卖次:SUM(SSJ>0,0),NODRAW;

成功率:=(卖次>10)*100*SUM(BSYL*(SSJ>0)>0,0)/卖次,NODRAW;

股数:=100*INTPART(QQ/RBJ/1.003/100),NODRAW;

差额:=(SSJ>0)*(SSJ*0.997-RBJ*1.003)*股数,NODRAW;

总盈利率:=100*SUM(差额,0)/QQ;

DA0:=HHV(IF(BARSCOUNT(C)=1,DATE,0),0);

年:=(DATETODAY(DATE)-DATETODAY(DA0))/365,NODRAW;

年收益:(年>=1)*总盈利率/年,NODRAW;

KKT:=STRCAT('计算',CON2STR(TOTALBARSCOUNT,0));

YE:=STRCAT('K线=',CON2STR(年,2));

SY:=STRCAT('年 收益 ',CON2STR(总盈利率,1));

SY2:=STRCAT('%(+',STRCAT(CON2STR((PE<0)*BSYL,1),')'));

百K:=STRCAT('% 信号 ', CON2STR(信号K%,1));

CG:=STRCAT('%K 成功率 ',CON2STR(成功率,1));

TX:=STRCAT(KKT,STRCAT(YE,STRCAT(SY,STRCAT(SY2,STRCAT(百K,CG)))));

DRAWTEXT_FIX(ISLASTBAR,0.0,1,0,TX),COLOR00FFFF;

DRAWTEXT_FIX(ISLASTBAR,0.02,0,0,STRCAT(HYBLOCK,'板块')),COLOR0000FF;

{PDA:=1; NBJ:=IF(JK<=1,YA王.BJ,JKGS.BJ)*PDA;

BAR:=HHV(NBJ>0,0); X0:=SUM(BAR,0);

NSJ:=IF(JK<=1,YA王.SJ,JKGS.SJ)*BAR;

BJ2:=IF(JK<=1,YA王.BJ2,0)*BAR;

SN:=BARSLAST(NSJ>0 OR BARSCOUNT(C)=1);

EX10:=HHV(NBJ,SN+1);

RE:=IF(BARSCOUNT(C)=1,0,REF(EX10,1));

BBJ:=IF(EX10>RE,NBJ,0); SSJ:=IF(EX10<RE,NSJ,0);

PE:=IF(JK<=1,YA王.PE,GSJK.PE)*BAR;

TB:=CALCSTOCKINDEX('999999SH','YA王',1);

PJ2:=IF(BJ2>0 AND JK=1,BJ2,BJ);

STICKLINE(BJ>0 OR BJ2>0,PJ2,PJ2,9,0),COLORFF00FF;

STICKLINE(SJ>0,SJ ,SJ,9,0),COLOR00FF00;

P预:=IF(ISLASTBAR=0,DRAWNULL,预警);

STICKLINE(ISLASTBAR,P预,P预,9,0),COLOR00FFFF;

预:=STRCAT(IF(BBJ>0,' 预警买点',IF(SSJ>0,' 预警卖点',IF(PE>0 AND BBJ=0 AND SSJ=0,

' 预警买点',' 预警卖点 '))),CON2STR(预警,2));

DRAWTEXT_FIX(ISLASTBAR,0.8,1,0,预),COLOR0088FF;

DRAWTEXT(BJ2>0 AND BBJ=0 AND JK=1,L,'短'),COLOR0088FF;};

以上是由“红股网”整理的“通达信必胜剑法主图指标公式(选股公式/源码)”全部内容,如稿件涉及版权等问题,请与我们联系删除或处理,客服邮箱hongguwang@qq.com,稿件内容仅为传递更多信息之目的,不代表本网观点,亦不代表本网站赞同其观点或证实其内容的真实性。