通达信大盘与个股指标公式
2021/2/22 18:38:31
中间线:0,COLORWHITE;
N日线:=30;
个股强弱:(CLOSE-MA(CLOSE,N日线))/MA(CLOSE,N日线)*100,LINETHICK1,COLORMAGENTA;
大盘强弱:(INDEXC-MA(INDEXC,N日线))/MA(INDEXC,N日线)*100,LINETHICK1,COLORCYAN;
行业强弱:(HY_INDEXC-MA(HY_INDEXC,N日线))/MA(HY_INDEXC,N日线)*100,COLORYELLOW,LINETHICK1;
{======显示位置的数据自己根据需要进行上下左右调整======}
左右位置:=0;
上下位置:=0;
左右平移:=0.15;
上下平移:=0;
涨停数:=CONST(INSUM(HYBLOCK,'涨幅',1,0));
个股排名:=CONST(INSORT(HYBLOCK,'涨幅',1,0));
HYPM1:=STRCAT('【',HYBLOCK);
HYPM2:=STRCAT(HYPM1,'】板块涨停 ');
HYPM3:=STRCAT(HYPM2,VAR2STR(涨停数,0));
HYPM4:=STRCAT(HYPM3,'支');
HYPM5:=STRCAT('█','██████████████');
HYPM4A:=STRCAT(HYPM4,'(无个股涨停)');
HYPM4B:=IF(涨停数<10,STRCAT(HYPM5,'█'),STRCAT(HYPM5,'██'));
DRAWTEXT_FIX(ISLASTBAR,左右位置,上下位置,0,IF(涨停数<1,DRAWNULL,HYPM4B)),COLORRED;
DRAWTEXT_FIX(ISLASTBAR,左右位置,上下位置,0,IF(涨停数>=1,HYPM4,HYPM4A)),COLORWHITE;
所属板块:=STRCAT(STRCAT(GNBLOCK,FGBLOCK),ZSBLOCK);
DRAWTEXT_FIX(CURRBARSCOUNT=3,左右平移,上下平移,0,所属板块),COLORRED;
投股 票网 www.tou18. cn
股市公式下载推荐