通达信情绪空间指标 可以显示连板高度、股票代码、连板个数,以及涨停个数 源码附图

{参数B1:控制"股票代码"的显示位置,可以根据显示情况调节
参数B2:控制"连板个数"的显示位置,可以根据显示情况调节
参数X1:如果X1=1,显示"涨停数"曲线以及对应的取值;
如果X1=0,则只显示曲线,不显示取值;默认X1=0;
参数X2:如果X2=1,显示"连板个数"曲线以及对应的取值;
如果X2=0,则只显示曲线,不显示取值;默认X2=0;
}

B1:=1.15;
B2:=0.06;
X1:=0;
X2:=0;

下跌:"880003$DECLINE",COLORGREEN NODRAW;
上涨:"880003$ADVANCE",COLORRED NODRAW;
跌停数:SCJYVALUE(24,2,0),COLORGREEN NODRAW;
涨停数:SCJYVALUE(24,1,0), COLOR5E409B NODRAW ;
连板高度:SCJYVALUE(30,1,0)COLORWHITE NODRAW;
连板个数:SCJYVALUE(23,2,0), COLOR808080,NODRAW;

LBGD:=连板高度;
TJ1:=LBGD;
TJ2:=REFX(TJ1,1);
NOTEXTLBGD1:IF(TJ1<2 AND TJ2>2,TJ2-1,TJ1),COLORD6A82E LINETHICK2;
NOTEXTLBGD2:IF(LBGD>1,LBGD,DRAWNULL), CIRCLEDOT COLORC0C0C0 ;
NOTEXTLBGD3:IF(LBGD>1 AND LBGD<REF(LBGD,1),LBGD,DRAWNULL),COLOR408000 LINETHICK2;{ COLOR32BC39}
NOTEXTLBGD4:IF(LBGD>1 AND LBGD>REFX(LBGD,1),LBGD,DRAWNULL),COLOR408000 LINETHICK2;
NOTEXTLBGD5:IF(LBGD>1 AND LBGD>REF(LBGD,1),LBGD,DRAWNULL),COLOR3AABDC LINETHICK2;
NOTEXTLBGD6:IF(LBGD>1 AND LBGD<REFX(LBGD,1),LBGD,DRAWNULL),COLOR3AABDC LINETHICK2;
NOTEXTLBGD7:IF(LBGD>1 AND LBGD>REF(LBGD,1) AND LBGD>4,LBGD,DRAWNULL),COLOR6A2EE9 LINETHICK2;
DRAWNUMBER(LBGD>1,LBGD,LBGD)DRAWABOVE;
HZT:=CONST(HHV(涨停数,300));
HLB:=CONST(HHV(LBGD,300));
HLBGS:=CONST(HHV(连板个数,300));
TEMP1:=HLB*涨停数/HZT;
NOTEXT涨停:HLB*涨停数/HZT,COLOR5E409B ;
NOTEXT涨停2:IF(TEMP1>0 AND X1=1,TEMP1,DRAWNULL),COLOR5E409B POINTDOT LINETHICK4;
DRAWNUMBER(涨停数>0 AND X1=1,TEMP1,涨停数)DRAWABOVE COLOR5E409B;
NOTEXT连板:HLB*连板个数/HLBGS, COLOR808080;
TEMP2:=HLB*连板个数/HLBGS;
NOTEXT连板2:IF(连板个数>0 AND X2=1,TEMP2,DRAWNULL), POINTDOT LINETHICK4 COLOR808080;
DRAWNUMBER(连板个数>1 AND X2=1,TEMP2*B2,连板个数)COLOR808080 DRAWABOVE;

股票代码:INSUM('历史连板股','LBZG',1,2),NODRAW COLOR6A2EE9;
T1:=股票代码;
E1:=MOD(INTPART(T1/100000),10);
E2:=MOD(INTPART(T1/10000),10);
E3:=MOD(INTPART(T1/1000),10);
E4:=MOD(INTPART(T1/100),10);
E5:=MOD(INTPART(T1/10),10);
E6:=MOD(T1,10);
DRAWTEXT(LBGD>5 AND LBGD>REFV(LBGD,1) AND LBGD>REFX(LBGD,1),LBGD*B1,VARCAT(VAR2STR(E1,0),VARCAT(VAR2STR(E2,0),VARCAT(VAR2STR(E3,0),VARCAT(VAR2STR(E4,0),VARCAT(VAR2STR(E5,0),VAR2STR(E6,0)))))))COLOR6A2EE9;
DRAWTEXT(ISLASTBAR,LBGD*B1,VARCAT(VAR2STR(E1,0),VARCAT(VAR2STR(E2,0),VARCAT(VAR2STR(E3,0),VARCAT(VAR2STR(E4,0),VARCAT(VAR2STR(E5,0),VAR2STR(E6,0)))))))COLOR6A2EE9;

WK:=WEEKDAY;
DRAWTEXT(WK=1,0,'一')COLOR808080;
DRAWTEXT(WK=2,0,'二')COLOR808080;
DRAWTEXT(WK=3,0,'三')COLOR808080;
DRAWTEXT(WK=4,0,'四')COLOR808080;
DRAWTEXT(WK=5,0,'五')COLOR808080;



未来函数检测结果如下:
该公式包含未来函数:REFX
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图