629.问:
上式能做成跟随光标就更好了
答(wzlhm):
光标移动可以参考一下:
b:=ma(c,30);
jc:=refx(cross(b,ma(b,2)+0.0001) or cross(ma(b,2),b+0.0001) ,1);
zq1:BARSLAST(jc=1)+1,LINETHICK1;//以上是你的源码
n:=SYSPARAM(1);
m:=barscount(c)-(n-zq1[n]+1);
zq11:=(m+1)*(m>=0);
a1:=FRACPART((zq11-1)/5)=0;
a2:=FRACPART((zq11)/5)=0;
hs:=v/capital*100;
lj:=sum(hs,5)*a2;
VERTLINE(a1 and zq11),COLORYELLOW;
STICKLINE(m=0,0,15,3,0),COLORMAGENTA;
DRAWNUMBER(ref(a2,1) and zq11,15,ref(lj,1),1),ALIGN2,COLORGREEN;
DRAWNUMBER(ISLASTBAR,15,sum(hs,barslast(a1)+1),1),COLORGREEN;
QUOTE:
630.问:
求在主图显示流通股+所属板块字样源码(分析家用)
答(无名山人):
给你一个.
Var1:=BARSLAST(DISPSTATUS=1)+1;
Var2:=DISPSTATUS=2;
Var3:=HHV(h ,Var1);
代码:='股票代码:'+STKLABEL;
资料:=' 流通盘'+FINANCE(7)+'万股'+'净资产'+FINANCE(35)+'元'+'每股收益'
+FINANCE(33)+'元'+'每股未分配'+FINANCE(32)+'元'+'市盈率'+DYNAINFO(39);
DRAWTEXT(Var2,Var3,代码+资料),align2,COLORCYAN;
答(多多):
drawtext(sysparam(2)=barpos,h,'所属板块:'+blkname),colorred,align3
放在主图公式之后!
答(阿福):
drawtext(barpos=sysparam(2),h,STKNAME+STKLABEL+'\n'+blkname),ALIGN4;
DRAWTEXT( SYSPARAM(2)=BARSCOUNT(C),l,
'〈流通盘〉'+NUMTOSTR(CAPITAL/100, 2)
+'〈市盈率〉'+NUMTOSTR(DYNAINFO(4), 2)
+'〈每股收益〉'+NUMTOSTR(FINANCE(33), 2)
+'〈每股净资〉'+NUMTOSTR(FINANCE(34), 2)
+'〈获利盘〉'+NUMTOSTR(winner(c)*100, 2)
+'%'),ALIGN3, coloryellow;
飞狐能用