TA的每日心情 | 开心 2024-9-20 00:45 |
---|
签到天数: 949 天 [LV.10]签到十级
六段
- 积分
- 36750
|
感谢斗K不是逗K师兄发的MAC底背离条件选股公式+ S; o" r6 i( ~/ Y/ F
我这里发一个,MACD指标公式,可以在图中标出顶和底的背离6 _* V# q9 w2 }( b
- a5 q) ?, H, l: g3 R/ r4 ]
在主图上右键点MACD的“修改当前指标公式” 然后拷如下列程序,名字自命名,我命名的是“MACD=背离”
8 D0 i0 W' f, X% Z3 J* i0 T& f- J5 I" @( _7 L! i
[/ t) b* L7 r0 Z
DIFF:EMA(CLOSE,12) - EMA(CLOSE,26);; |; T; x1 F9 w$ G; {& C# w
DEA:EMA(DIFF,9);, N4 W, K; ~$ w, d3 B
MACD:2*(DIFF-DEA), COLORSTICK;
* E4 s& N$ X& ? e8 MA1:=BARSLAST(REF(CROSS(DIFF,DEA),1));
4 o1 C& R& Q' c9 I底背离:=REF(CLOSE,A1+1)>CLOSE AND DIFF>REF(DIFF,A1+1) AND CROSS(DIFF,DEA);
- H2 o& {- C/ ]- n4 B2 QSTICKLINE(底背离,0,0.1,8,0),COLORRED;
* F% `. S; w3 m+ @; W2 s MDRAWLINE(A1=0,DEA,底背离,DEA,0),COLORRED,LINETHICK2;
* |4 C1 ]! f: w: E9 O) n* a& TA2:=BARSLAST(REF(CROSS(DEA,DIFF),1));7 O0 D. E6 R ?+ p0 [' P8 b, Y
顶背离:=REF(CLOSE,A2+1)<CLOSE AND REF(DIFF,A2+1)>DIFF AND CROSS(DEA,DIFF);: j6 S B- i0 o" w4 p( G9 Y* X
DRAWLINE(A2=0,DEA,顶背离,DEA,0),COLORGREEN,LINETHICK2;( x5 a# n6 @) @% o' Z
|
|