TA的每日心情 | 开心 2019-5-15 08:50 |
---|
签到天数: 134 天 [LV.7]签到七级
四段
- 积分
- 9950
|
网上抄来的,先看效果,下面第二栏就是,第三栏是传统的MACD,相比传统的MACD图,这个用颜色标明了红绿柱长短变化+ w6 L6 Q. Z% t( y" k: {9 c
/ i' M8 g. ?" C
公式:; H- P! U6 u4 }0 V* P
P:=13;S:=5;M:=1;
( R* Z6 z. ~" X& {8 nDIFF:EMA(C,S)-EMA(C,P);( \. W+ H5 H1 r: J7 `6 q
DEA:EMA(DIFF,M),COLORRED;3 E0 L% w! ^1 r5 @9 m& I
MACD:2*(DIFF-DEA),COLORSTICK;
& \1 b. Q' h. C6 I: I% zP1:=P;S1:=S;
; I7 y5 Z3 s/ |7 E; ?) E0 MDIFF1:EMA(C,S1)-EMA(C,P1);
) }, D y; [% Q! NDEA1:EMA(DIFF,M),COLORRED;
4 E* F' M3 S3 g- G4 P4 vMACD1:=2*(DIFF1-DEA1);0 m' t) Z# n7 ]5 c" d
MACD2:=DEA;6 p9 g) O3 F$ |# s7 \0 D% r
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,3,0 ),COLOR00AAFF;( E& W0 `7 B* o k+ _ ~4 y/ S9 G/ g
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,1.8,0 ),COLOR00BBFF; _0 ~! P' v7 b, l# @. M6 t; X
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,1.3,0 ),COLOR00CCFF;# w! P7 C3 s" ?
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,1.2,0 ),COLOR00DDFF;1 u! P) c. s" {: x. N4 \) e/ r
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,1,0 ),COLOR00EEFF;% T1 _# F/ d2 p* x7 }$ U* K5 d
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2>0,0,MACD2,0.5,0 ),COLOR00FFFF;
" M. y* E1 H! a5 mSTICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,3.4,0 ),COLOR0000AA;/ M0 @. P% ?% J' h" q9 c: u |3 ?- E
STICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,3.2,0),COLOR0011BB;& m' x! G$ {: ?3 a8 P' M
STICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,3,0),COLOR0022CC;
+ s# p5 a# ]+ ? M- aSTICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,2,0),COLOR0033DD;! W! m z j2 |8 O2 Z5 e4 ~4 s
STICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,1,0),COLOR0044EE;( ^. x* j$ p) ]3 a1 Q1 J0 g
STICKLINE(MACD2>REF(MACD2,1)AND MACD2>0,0,MACD2,0.5,0),COLOR0055FF;* o F1 |7 t5 _! ^$ [5 c
STICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,3.4,0),COLORAA00BB;
0 k( Q& c, c, T+ v8 DSTICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,3.2,0),COLORBB11BB;
" s3 f) y, o. H9 pSTICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,3,0),COLORCC22BB;
) v% I6 u3 y3 P6 N9 I7 V$ f N) xSTICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,2,0 ),COLORDD33BB;
$ A: ?9 X8 r$ m' i% PSTICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,1,0),COLOREE44BB;
6 v; q' ]$ y! ?STICKLINE(MACD2>REF(MACD2,1)AND MACD2<=0,0,MACD2,0.5,0 ),COLORFF55BB;
9 K) p1 Y. i* L% S* VSTICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,3,0 ),COLORFF7700;
`# _4 l3 J7 `4 gSTICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,1.5 ,0 ),COLORFF8811;
6 y4 i: x* l0 ySTICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,1.2,0 ),COLORFFAA22;
# D( B' K' E% m; W. \STICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,1.0 ,0 ),COLORFFBB33;) t8 a- E9 J) ?. G! I
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,0.8 ,0 ),COLORFFDD44;. M( `8 ~) d; V9 P
STICKLINE(MACD2<=REF(MACD2,1)AND MACD2<=0,0,MACD2,0.5 ,0 ),COLORFFFF55;
3 c6 V4 b+ S" |R:=(HHV(DEA,100)+ABS(LLV(DEA ,100)))/2;
# h: E- q F _% v/ _3 ]; u8 k" \ xR/4,POINTDOT,COLORFFFF00;
2 }* [, f! v8 Z" g( i) L7 AR/2,POINTDOT,COLORFFFF00;
6 y% X9 Z' x' T# ~: VR/4*3,POINTDOT,COLORFFFF00;
4 h1 Z; T% j. h5 B d-R/4,POINTDOT,COLORFFFF00;7 d' o; C/ [* P2 m n- i- I; Y
-R/2,POINTDOT,COLORFFFF00;8 L; U5 v( ^# J: G
-R/4*3,POINTDOT,COLORFFFF00;( O$ {0 w& F% i1 V% N' [
9 Y1 c2 j0 |' ^, A
2 L" {9 _/ f5 q# j, f' b使用方法:按CTRL+F打开公式管理器,公式组选定技术指标公式后,点右边新建按钮打开指标公式编辑器,公式名称MACD2,公式类型趋势型,画线方法附图,上面公式内容复制到编辑框内,点确定编辑完毕,如下图
; G( H9 h2 l7 ]- m( d- V' h! T' {
: g7 w" B& ]. ]" f/ ?
Z~后在K线图窗口下的某个副图上点一下,输入公式名称MACD2,回车就可以了
4 V1 q7 g# N2 ~( g1 B7 B2 d# f2 E) _
|
|