以上指标公式错误较多,修改了一下,希望能帮到你dif:=ema(close,9)-ema(close,18);dea:ema(dif,7);macd:=2*(dif-dea);d:=backset(dif<ref(dif,1),2);stickline(macd>=0 and macd>=ref(macd,1),0,macd,1,0),colorred;stickline(macd>=0 and macd<ref(macd,1),0,macd,1,0),colorgreen;stickline(macd<0 and macd>=ref(macd,1),0,macd,1,0),colorblue;stickline(macd<0 and macd<ref(macd,1),0,macd,1,0),colorgreen;jc:=cross(dif,dea) and dif<0.3;drawicon((cross(dif,dea) and dif<0.3),0,1); 20210311
diff:=ema(dclose,12)-ema(dclose,26);dea:=ema(diff,9);macd:=(diff-dea)*2;xg:llv(macd,3)>0 and macd>ref(macd,1) and ref(macd,1)<ref(macd,2) and ref(macd,2)<ref(macd,3) and macd>=0.15;