精品看盘公式 【K线主图 源码 父子篇】
-
相关简介:{大盘K线} KK:=INDEXO;HH:=INDEXH;DD:=INDEXL;CC:=INDEXC; DP:=EMA(INDEXC,500)/EMA(C,500); STICKLINE(CCREF(CC,1),(HH+H)/DP,(DD+L)/DP,0,1),COLORred,linethick3; STICKLINE(CCREF(CC,1),(KK+O)/DP,(CC+C)/DP,6,1),COLORred,linethick3; STICKLINE(CCREF(CC,1),(HH+H)/D
-
文章来源:股海网作者:股海网发布时间:2015-04-08浏览次数:
{大盘K线}
KK:=INDEXO;HH:=INDEXH;DD:=INDEXL;CC:=INDEXC;
DP:=EMA(INDEXC,500)/EMA(C,500);
STICKLINE(CC>REF(CC,1),(HH+H)/DP,(DD+L)/DP,0,1),COLORred,linethick3;
STICKLINE(CC>REF(CC,1),(KK+O)/DP,(CC+C)/DP,6,1),COLORred,linethick3;
STICKLINE(CC<REF(CC,1),(HH+H)/DP,(DD+L)/DP,0,0),COLOR00FF00,LINETHICK3;
STICKLINE(CC<REF(CC,1),(KK+O)/DP,(CC+C)/DP,6,0),COLOR00FF00,LINETHICK3;
{波段}
JJ:=(CLOSE+HIGH+LOW)/3;
A:=EMA(JJ,10);
B:=REF(A,1);
STICKLINE(A>B,A,B,5,0),COLORYELLOW;
STICKLINE(A<B,A,B,5,0),COLORBLUE;
{支撑与压力}
AA100:=REF(c,5)=HHV(c,2*5+1);
B100:=FILTER(AA100,5);
C100:=BACKSET(B100,5+1);
HD00:=FILTER(C100,5);
AA200:=REF(c,5)=LLV(c,2*5+1);
B200:=FILTER(AA200,5);
C200:=BACKSET(B200,5+1);
Ld00:=FILTER(C200,5);
AB00:=REF(C,BARSLAST(HD00));
Z00:=REF(L,BARSLAST(LD00));
T100:=BARSLAST(HD00)<BARSLAST(LD00) AND NOT(HD00) ;
T200:=BARSLAST(HD00)>BARSLAST(LD00) AND NOT(LD00);
峰:IF(T100,AB00,AB00),COLORred,linethick3,POINTDOT,pRECIS2;
谷:IF(T200,Z00,Z00),COLORMAGENTA,linethick3,POINTDOT,pRECIS2;
{两线}
生命线:MA(CLOSE,15),COLORred,linethick3;
短线持股线:MA(REF(LLV(C,2),1),2),COLORYELLOW,LINETHICK2;
{基本}
流通盘大小:=FINANCE2(37)/1000000*100;
DRAWTEXTABS(20,320,'流通盘大小:'+NUMTOSTRN(流通盘大小,2)+'亿'),LINETHICK2,ColorFFAA00;
DRAWTEXTABS(20,240,'板块:'+BKNAME),Colorcyan,LINETHICK2;
DRAWTEXTABS(20,300,'证券代码: '+STKLABEL+' 证券名称: '+STKNAME+''),ColorFFAA00,LINETHICK2;
ztsp:=ref(c,1);
DRAWTEXTABS(640,20,'前收:'+ztsp+' '),colorwhite,LINETHICK1;
DRAWTEXTABS(710,20,'最新:'+c+' '),colorwhite,LINETHICK1;
DRAWTEXTABS(780,20,'最高:'+h+' '),COLOR0000FF,LINETHICK1;
DRAWTEXTABS(850,20,'最低:'+l+' '),COLOR00FF00,LINETHICK1;
Z,f:=(c/ref(c,1)-1)*100;
DRAWTEXTABS(920,20,'涨幅:'+Z,f+'%'),colorwhite,LINETHICK1;
年1:=YEAR;
月1:=MONTH;
日1:=DAY;
星期:=WEEKDAY;
时:=HOUR;
分:=MINUTE;
秒:=TIME;
wyy2:=LMONTH;
wyy3:=LDAY;
DRAWTEXTABS(120,260,NUMTOSTR(年1)+'年'+NUMTOSTR(月1)+'月'+NUMTOSTR(日1)+'日 星期'+NUMTOSTR(星期)+
' 北京时间: '+STRLEFT(NUMTOSTRN(IF(CURRENTTIME<10000,0,CURRENTTIME),0),IF(CURRENTTIME>=10000 AND
CURRENTTIME<100000,1,2))+'点 '+STRMID(NUMTOSTRN(CURRENTTIME,0),IF(CURRENTTIME<10000,1,IF(CURRENTTIME>=10000 AND
CURRENTTIME<100000,2,3)),2)+'分 '+STRRIGHT(NUMTOSTRN(CURRENTTIME,0),2)+'秒'),LINETHICK2,COLORyellow;
DRAWTEXTABS(20,260,'农历:'+NUMTOSTRN(wyy2,0)+'月'+NUMTOSTRN(wyy3,0)+'日'),LINETHICK2,COLORyellow;
XDLR:=IF(AMOUNT*(DYNAINFO(95)+DYNAINFO(94)+DYNAINFO(93))>0,SUM(((AMOUNT-AMOUNT*(DYNAINFO(95)+DYNAINFO(94)+DYNAINFO(93)))/10000),0),0);
XDLC:=IF(AMOUNT*(DYNAINFO(98)+DYNAINFO(97)+DYNAINFO(96))>0,SUM(((AMOUNT-AMOUNT*(DYNAINFO(98)+DYNAINFO(97)+DYNAINFO(96)))/10000),0),0);
DRAWTEXTABS(20,280,'上涨家数:'+NUMTOSTRN(DYNAINFO(69),0)+' 家'),LINETHICK2,COLOR0000FF;
DRAWTEXTABS(150,280,'下跌家数:'+NUMTOSTRN(DYNAINFO(70),0)+' 家'),LINETHICK2,COLOR00FF00;
DRAWTEXTABS(280,280,'平盘家数:'+NUMTOSTRN(DYNAINFO(71),0)+' 家'),LINETHICK2,ColorFFAA00;