通达信布林均线主图指标公式
通达信复合周期MACD指标公式
通达信布林均线主图指标公式:
P:=2;M1:=24;M2:=80;M3:=160;
{bbi:(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4,COLOR00FF00;{多空线}}
MID中轨:=MA(CLOSE,M1);
MA80:MA(CLOSE,M2);
MA160:MA(CLOSE,M3);
VART1:=POW((C-MID中轨),2);
VART2:=MA(VART1,M1);
VART3:=SQRT(VART2);
UPPER:=MID中轨+P*VART3;
LOWER:=MID中轨-P*VART3;
boll:=REF(MID中轨,1);
UPPEB上轨:REF(UPPER,1),COLOR333333,LINETHICK2;
LOWEB下轨:REF(LOWER,1),COLOR333333,LINETHICK2;
{变色中轨}
AA:=MID中轨;
BB:AA>REF(AA,1),LINETHICK0;
MID中轨,COLORFFFFFF,DOTLINE;
IF(BB,MID中轨,DRAWNULL),COLORRED,DOTLINE;
stICKLINE(CLOSE>=OPEN AND CLOSE<=MID中轨,OPEN,CLOSE,2,0),COLOR000077;
STICKLINE(CLOSE>=OPEN AND CLOSE<=MID中轨,H,L,0,0),COLOR000077;
STICKLINE(OPEN>CLOSE AND CLOSE<=MID中轨,OPEN,CLOSE,2,0),COLOR777700;
STICKLINE(OPEN>CLOSE AND CLOSE<=MID中轨,H,L,0,0),COLOR777700;
STICKLINE(crOSS(CLOSE,MID中轨),CLOSE,OPEN,0.5,0),COLOR0080FF;
通达信涨停天机副图指标公式