代码:
复制内容到剪贴板
代码:
{空心化阴线}
STICKLINE(O>C,O,C,2,1),COLORCYAN;
{基本参数}
C2:=REF(C,1);
KL1:=(C-C2)*100/C2;
KL2:=(C2-C)*100/C2;
BF5:=5-0.01*100/C2;
BF10:=10-0.01*100/C2;
{涨停K线}
ZT:=IF(KL1>=BF10,1,0);
DRAW_ZTK:STICKLINE(ZT,O,C,2,0),COLORYELLOW;
DRAW_ZTL:STICKLINE(ZT,H,L,0,0),COLORYELLOW;
{跌停K线}
DT:=IF(KL2>=BF10,1,0);
DRAW_DTK:STICKLINE(DT,O,C,2,0),COLORGREEN;
DRAW_DTL:STICKLINE(DT,H,L,0,1),COLORGREEN;
{大涨K线}
DZ:=IF(KL1>=BF5 AND KL1
DRAW_DZL:STICKLINE(DZ,H,L,0,1),COLORRED;
{大跌K线}
DD:=IF(KL2>=BF5 AND KL1
DRAW_DDL:STICKLINE(DD,H,L,0,1),COLORCYAN;
注意:加代码的时候避免和原指标的变量重复。