行业指数:HY_INDEXC,NODRAW;
DRAWKLINE(HY_INDEXH,HY_INDEXO,HY_INDEXL,HY_INDEXC);
MA5:MA(HY_INDEXC,5),COLORWHITE;
{MA10:MA(HY_INDEXC,10),COLORYELLOW,LINETHICK2};
DRAWTEXT_FIX(1,1,1,1,STRCAT(STRCAT(CON2STR(HY_INDEXADV,0),'/'),STRCAT(CON2STR(HY_INDEXDEC,0),' '))),COLORGRAY;
{彩色10日均线}
MA_HYZS_CLR:=MA(HY_INDEXC,10);{需彩色的均线}
{彩色均线,上涨彩色区分}
{本色、底色}
NOTEXTMA:MA_HYZS_CLR,COLORGRAY;
{彩色、替换}
NOTEXTMCLR:IF((MA_HYZS_CLR>REF(MA_HYZS_CLR,1)),MA_HYZS_CLR,DRAWNULL),COLORMAGENTA,LINETHICK2;
{以下代码含有未来函数,可实现上升拐点开始绘彩色线,但软件上会有使用未来数据的提示};
{NOTEXTMCLR:IF((MA_HYZS_CLR>REF(MA_HYZS_CLR,1) AND CLOSE>MA_HYZS_CLR) OR (BARSNEXT(MA_HYZS_CLR>REF(MA_HYZS_CLR,1) AND CLOSE>MA_HYZS_CLR)=1),MA_HYZS_CLR,DRAWNULL),COLORRED,LINETHICK2};