1樓:奭
a:=cross(macd.dif,macd.dea);
ts:=ref(barslast(a),1);
a1:=cref(macd.dif,ts+1);
a and a1 and a2;
請高手編寫個通達信的簡單公式:macd紅綠柱子背離
2樓:匿名使用者
macd頂底背離(同時包含kdj背離,rsi背離)
公式如下:
diff:ema(close,12) - ema(close,26);
dea:ema(diff,9);
macd:2*(diff-dea),colorstick;
a1:=barslast(ref(cross(diff,dea),1));
b1:=ref(c,a1+1)>c and ref(diff,a1+1)c and ref("kdj.k"(9,3,3),a2+1)<"kdj.
k"(9,3,3) and cross("kdj.k"(9,3,3),"kdj.d"(9,3,3));
a3:=barslast(ref(cross("rsi.rsi1"(6,12,24),"rsi.rsi2"(6,12,24)),1));
b3:=ref(c,a3+1)>c and ref("rsi.rsi1"(6,12,24),a3+1)<"rsi.
rsi1"(6,12,24) and cross("rsi.rsi1"(6,12,24),"rsi.rsi2"(6,12,24));
c1:=barslast(ref(cross(dea,diff),1));
d1:=ref(c,c1+1)diff and cross(dea,diff);
c2:=barslast(ref(cross("kdj.d"(9,3,3),"kdj.k"(9,3,3)),1));
d2:=ref(c,c2+1)"kdj.k"(9,3,3) and cross("kdj.d"(9,3,3),"kdj.k"(9,3,3));
c3:=barslast(ref(cross("rsi.rsi2"(6,12,24),"rsi.rsi1"(6,12,24)),1));
d3:=ref(c,c3+1)"rsi.rsi1"(6,12,24) and cross("rsi.rsi2"(6,12,24),"rsi.rsi1"(6,12,24));
macd底背:if(b1>0,-0.1,0),colorred,pointdot;
kdj底背:if(b2>0,-0.1,0),colorff00ff,pointdot;
rsi底背:if(b3>0,-0.1,0),coloryellow,pointdot;
macd頂背:if(d1>0,0.1,0),color00ff00,pointdot;
kdj頂背:if(d2>0,0.1,0),colorffcc66,pointdot;
rsi頂背:if(d3>0,0.1,0),colorwhite,pointdot;
stickline(b1>0,-0.1,0,2,0),colorred;
stickline(b2>0,-0.1,0,2,0),colorff00ff;
stickline(b3>0,-0.1,0,2,0),coloryellow;
stickline(d1>0,0.1,0,2,0),color00ff00;
stickline(d2>0,0.1,0,2,0),colorffcc66;
stickline(d3>0,0.1,0,2,0),colorwhite;
請高手幫助編寫通達信公式 MACD指標死叉後3日內又金叉。謝謝
xg cross macd.dif,macd.dea and count cross macd.dea,macd.dif 3 1 求高手寫乙個通達信60分鐘macd金叉的條件預警公式!謝謝!dif ema close,12 ema close,26 dea ema dif,9 macd dif de...
請高手寫個通達信條件選股公式,當天股價同時突破5日均線和10日均線
a ma c,5 b ma c,10 d cross c,a e cross c,b xg d and e 測試通過,希望能夠幫助你 這個氣壓不足很危險的感覺。1965 cross c,ma c,25 個人認為不要使用上穿函式,有很多具備條件的票進不來,容易放在真正自己需要的票,o ma c,25 ...
求高手寫通達信選股公式,表示30日均線剛剛拐頭向上1天或2天或3天或4天或5天
ma1 ma c,30 output barslast ma1 ref ma1,1 5 你試試這個 ma1 ma c,30 count ma1 ref ma1,1 5 1 and ma1 ref ma1,1 ref ma c,30 5 ref ma c,30 6 and count ma c,30 ...