通达信一条均线主图指标公式
2020/5/19 18:28:30
T:=20;N:=2;M:=30;
DIRECTION:=CLOSE-REF(CLOSE,T);
VOLATILITY:=SUM(ABS(CLOSE-REF(CLOSE,1)),T);
ER:=SUM(ABS(DIRECTION/VOLATILITY),1);
FASTC:=2/(N+1);
SLOWC:=2/(M+1);
SMOOTH:=ER*( FASTC- SLOWC)+ SLOWC;
SE:=SMOOTH* SMOOTH;
YY:=REF(CLOSE,1)+SE*(CLOSE-REF(CLOSE,1));
AA:=IF(SUM(1,0)=T+1,YY,0);
BB:=BARSLAST(AA>0);
CC:=REF(CLOSE,BB);
AMA1:=REF(CC,1)+SE*CLOSE-REF(CC,1);
AMA2:DMA(CLOSE,SE),COLORFFAA00,LINETHICK2;
BUY:=CROSS(AMA1,AMA2)AND AMA2>REF(AMA2,1);
SELL:=CROSS(AMA2,AMA1);
持股:AMA1>AMA2,NODRAW,COLORRED;
持币:AMA1<=AMA2,NODRAW,COLORGREEN;
趋势向上:IF(AMA2>REF(AMA2,1),AMA2,DRAWNULL),COLORFF00FF,LINETHICK2;
投股 票网 www.tou1 8.cn
股市公式下载推荐