主图显示股票所属证监会行业板块、主要财务指标和当天涨跌停价
说明:不是飞狐系统平时显示的又长又臭的“所属板块”,而是自定义的股票所属证监会行业板块!比如:电力、房地产……等。
{主图显示股票所属证监会行业板块、主要财务指标和当天涨跌停价}
{涨停价、跌停价(支持ST、*ST、S股)}
AA1:=STRFIND(STKNAME,'S',0)=0;
gws:=FRACPART(ref(c,1)*IF(AA1,10,5));
qz:=INTPART(ref(c,1)*IF(AA1,10,5))/100;
涨停价:=ref(c,1)+qz+if(gws>0.4,0.01,0),COLORRED,LINETHICK;
跌停价:=ref(c,1)-qz-if(gws>0.4,0.01,0),COLORGREEN,LINETHICK;
DRAWTEXTEX(C,0,410,0,'▲涨停价:'+数字转化为字符串(涨停价,2)),COLORRED;
DRAWTEXTEX(C,0,410,10,'▼跌停价:'+数字转化为字符串(跌停价,2)),COLORGREEN;
DRAWTEXTEX(CLOSE,1,1,0,'上涨:'+NUMTOSTR(INDEXADV,0)+'家'),COLOR0066FF;
DRAWTEXTEX(CLOSE,1,80,0,' 下跌:'+NUMTOSTR(INDEXDEC,0)+'家'),COLOR99FF99;
DRAWTEXTEX(CLOSE,1,160,0,' 平盘:'+NUMTOSTR(PINGPAN,0)+'家'),COLOREEEEEE;
DRAWTEXTEX(c,1,1,60,'所属板块:'+STRLEFT(BLKNAME,STRFIND(BLKNAME,',',1)-1)+'\n'+'流通股:'+NUMTOSTR(FINANCE(7)/10000,2)+'亿'+'\n'+'流通比:'+NUMTOSTR(FINANCE(7)/FINANCE(1)*100,0)+'%'+'\n'+'股收益:'+NUMTOSTR(FINANCE(33),3)+'元'+'\n'+'市盈率:'+NUMTOSTR(DYNAINFO(39),0)+'\n'+'净资产:'+NUMTOSTR(FINANCE(34),2)+'元'+'\n'+'主营收:'+NUMTOSTR(FINANCE(20)/10000,2)+'亿'+'\n'+'上市:'+NUMTOSTR(REF(YEAR,(BARSCOUNT(CLOSE) - 1)),0)+ '(' + NUMTOSTR(BARSCOUNT(C),0 )+')'+'\n'+'更新:'+ NUMTOSTR(FINANCE( 0),0 )+'\n'),ALIGN4,colorCCFFCC;
DRAWTEXTEX(C,1,480,960,'历史最高价:'+NUMTOSTR(hhv(h,datacount),2)+'('+NUMTOSTR((C-hhv(H,datacount))/hhv(H,datacount)*100,0)+'%)'),COLORFFCC00;
DRAWTEXTEX(C,1,480,1000,'历史最低价:'+NUMTOSTR(llv(l,datacount),2)+'('+NUMTOSTR((C-llv(L,datacount))/llv(L,datacount)*100,0)+'%)'),COLORFFCC00;
DRAWTEXTEX(C,1,650,960,'年内最高价:'+NUMTOSTR(HHV(H,250),2)+'('+NUMTOSTR((C-hhv(H,250))/hhv(H,250)*100,0)+'%)'),COLOR99FF66;
DRAWTEXTEX(C,1,650,1000,'年内最低价:'+NUMTOSTR(LLV(L,250),2)+'('+NUMTOSTR((C-llv(L,250))/llv(L,250)*100,0)+'%)'),COLOR99FF66;
DRAWTEXTEX(C,1,820,960,'半年最高价:'+NUMTOSTR(HHV(H,120),2)+'('+NUMTOSTR((C-hhv(H,120))/hhv(H,120)*100,0)+'%)'),COLORFFCC00;
DRAWTEXTEX(C,1,820,1000,'半年最低价:'+NUMTOSTR(LLV(L,120),2)+'('+NUMTOSTR((C-llv(L,120))/llv(L,120)*100,0)+'%)'),COLORFFCC00;
DRAWTEXTEX(C,1,310,960,'所见最高价:'+NUMTOSTR(SYSPARAM(4),2)+'('+NUMTOSTR((C-SYSPARAM(4))/SYSPARAM(4)*100,0)+'%)'),COLOR99FF66;
DRAWTEXTEX(C,1,310,1000,'所见最低价:'+NUMTOSTR(SYSPARAM(5),2)+'('+NUMTOSTR((C-SYSPARAM(5))/SYSPARAM(5)*100,0)+'%)'),COLOR99FF66;
|