持仓:IF(CLOSE>=SAR(4,2,20),sar(4,2,20),
DRAWNULL),CIRCLEDOT,COLORRED;
空仓:IF(CLOSE<=SAR(4,2,20),SAR(4,2,20),
DRAWNULL),CIRCLEDOT,COLORGREEN ;
获利%:WINNER(CLOSE)*100,NODRAW,COLORWHITE;
V1:=Abs((2*CLOSE+HIGH+LOW)/4-MA(CLOSE,20))/MA(CLOSE,20);
V2:=(1-7/100)*(DMA(CLOSE,V1));
V3:=(1+7/100)*(DMA(CLOSE,V1));
V5:=MA((LOW+HIGH+CLOSE)/3,5);
支撑:REFDATE(V2,DATE),POINTDOT,LINETHICK4,COLORCC66FF;
阻力:REFDATE(V3,DATE),POINTDOT,LINETHICK4,COLORFF0033;
{ _通达信股票指标公式}
DRAWKLINE(H,O,L,C);
涨停:=IF((C-REF(C,1))*100/REF(C,1)>=(10-0.01*100/REF(C,1)),1,0);
STICKLINE(涨停,OPEN,CLOSE,2,0),COLORMAGENTA;
STICKLINE(涨停,H,L,0,0),COLORMAGENTA;
跌停:=IF((REF(C,1)-C)*100/REF(C,1)>=(10-0.01*100/REF(C,1)),1,0);
STICKLINE(跌停,OPEN,CLOSE,2,0),COLORBLUE;
STICKLINE(跌停,H,L,0,1),COLORBLUE;