稳赚趋势主图通达信指标公式源码 下载本文

指标主要是依据股价的10日和20日均线为基础,控制K线变色,而其均线也随趋势改变颜色。

结合指标源码看图:

ZJ:EMA(C,10),COLOR0000FF; HY:EMA(C,20),COLORFF00FF;

IF(ZJ>REF(ZJ,1),ZJ,DRAWNULL),COLORRED,LINETHICK2; IF(ZJ<=REF(ZJ,1),ZJ,DRAWNULL),COLORGREEN,LINETHICK2; IF(HY>REF(HY,1),HY,DRAWNULL),COLORMAGENTA,LINETHICK2; IF(HY ZJ,HIGH,L,0,0),COLORRED; STICKLINE(CLOSE > ZJ,C,OPEN,2.5,0),COLORRED; STICKLINE(CLOSE = ZJ,H,L,3,0),COLORWHITE; STICKLINE(CLOSE < ZJ,H,L,0,0),COLORYELLOW; STICKLINE(CLOSE < ZJ,O,C,2.5,0),COLORYELLOW;

STICKLINE(CLOSE < HY,OPEN,CLOSE,2.5,0),COLORCYAN; STICKLINE(CLOSE < HY,HIGH,L,0,0),COLORCYAN;