SLOPE函数---指标交流
加微信:zb-mart免费验证!
{N:1 180 2 ; M 1 180 21}
VAR1:=EMA(C,N);
VAR2:=EMA(SLOPE(C,M)*20+C,42);
VAR3:=CROSS(VAR1,VAR2);
VAR4:=CROSS(VAR2,VAR1);
MA10:=MA(C,10);
MA20:=MA(C,20);
IF(MA10>=MA20,MA20,DRAWNULL),COLORRED;
IF(MA10<MA20,MA10,DRAWNULL),COLORGREEN;
DRAWTEXT(VAR3,LOW*0.95,'买'),COLORYELLOW,LINETHICK3;
DRAWTEXT(VAR4,HIGH*1.028,'卖'),COLORGREEN,LINETHICK3;
STICKLINE(VAR1=VAR2,LOW,HIGH,0,0),COLORRED;
STICKLINE(VAR1>=VAR2,CLOSE,OPEN,2,0),COLORRED;
STICKLINE(VAR1>=VAR2,CLOSE,OPEN,2,0),COLORRED;
STICKLINE(VAR1>=VAR2,CLOSE,OPEN,2,0),COLORRED;
STICKLINE(VAR1>=VAR2,CLOSE,OPEN,2,0),COLORRED;
STICKLINE(VAR1<VAR2,CLOSE,OPEN,2,0),COLORGREEN;
STICKLINE(VAR1<VAR2,CLOSE,OPEN,2,0),COLORGREEN;
STICKLINE(VAR1<VAR2,CLOSE,OPEN,2,0),COLORGREEN;
STICKLINE(VAR1<VAR2,CLOSE,OPEN,2,0),COLORGREEN;
STICKLINE(VAR1<VAR2,LOW,HIGH,0,0),COLORGREEN;