TA的每日心情 | 开心 2019-5-15 08:50 |
---|
签到天数: 134 天 [LV.7]签到七级
四段
- 积分
- 9950
|
DIF:= EMA(CLOSE,12)-EMA(CLOSE,26);
+ e$ F0 O0 H! P, m. f3 c$ L8 DDEA:= EMA(DIF,9);1 K1 v/ q0 @& g2 U' `: N
MACD:= (DIF-DEA)*2;
' S5 u- C0 D3 u w4 t$ Q' W5 ?
! C6 k' f' U1 l( S4 L# H# \均值:= SUM(ABS(MACD), 100)/100; d% o% v W$ [
NOTEXT起死回生:= REF(MACD, 2) > REF(MACD, 1) AND REF(MACD, 1) < 均值*0.1 AND & L) Y+ _8 J5 @: s
REF(MACD, 1)>=0 AND REF(MACD, 1) < MACD;3 Q+ d% j0 ~$ R0 M; P
金叉失败:= REF(MACD, 2) < REF(MACD, 1) AND REF(MACD, 1) > 0-均值*0.1 AND
. H0 l' ?# b8 h' z( z REF(MACD, 1)<=0 AND REF(MACD, 1) > MACD;% V% `' B/ d* h' Q( D; ?7 ?" m. \
* x, d X9 O% U! O
AA1A:= BARSLAST(CROSS(DEA, DIF))+1;5 \! }8 o9 ~3 _/ U' G2 ]8 `
AA1B:= IF(NOTEXT起死回生 OR 金叉失败, BARSLAST(NOTEXT起死回生 OR 金叉失败)+3, 99999);
" v+ | }% B wAA1:= IF(AA1B<AA1A, AA1B, AA1A);
3 Y* S5 j! a c7 q* ]/ B- m% ~8 ?/ b% H! R
AA2A:= REF(BARSLAST(CROSS(DEA, DIF)), AA1)+1;
0 _: X; }" ]3 a( T( W" i& R2 OAA2B:= IF(REF(NOTEXT起死回生 OR 金叉失败, AA1), REF(BARSLAST(NOTEXT起死回生 OR 金叉失败), AA1), 99999)+3;
5 C: K: h1 v0 ?+ Y- ~# h) KAA2:= IF(AA2B<AA2A, AA2B, AA2A);
! m1 e" L% @! y4 ]1 T1 i7 z
3 n+ u. V& Q% b4 K+ x8 p9 vDIFZ~小值:= LLV(DIF, AA1+AA2);& l/ L+ O, o0 D1 I
DIFZ~小日:= LLVBARS(DIF, AA1+AA2);! d7 a- x- W( s; W4 W
DBL1:= IF(DIFZ~小日<=AA1, 0, 1);
" M( D' w+ f7 a* S4 ~! SDBL2:= IF(DBL1=1 AND C<REF(C, DIFZ~小日) AND DIF>REF(DIF, DIFZ~小日), 1, 0);
4 W6 [1 t+ D6 ?" w: fDBL:= IF(DBL1=0, 0, DBL2);9 m! {' ?! L; F, k: i2 P
- Z# l9 Y$ d; q% U7 E A" t
DBLJC: DBL AND (CROSS(DIF, DEA) OR NOTEXT起死回生) AND DIF>REF(DIF, 1);
; R3 ]9 U/ `! c
! A. g$ l4 A- F8 C' T# J: ?! Y) U2 C
) H) r2 T% W0 }1 s1 \/ Y
按下面的来,注意是选股公式,不是指标公式,还有公式名称不能太长。
! J' w0 y! ^$ k/ l( G" L: b- a2 I8 M4 b! g* c5 c: a0 k: C9 p# w- U" Z2 r# V% `
/ |: ]9 v& }3 v2 S! ?" v! I DIF:= EMA(CLOSE,12)-EMA(CLOSE,26);2 a x3 D( c& O* a9 W: H P- \
; E6 c8 |5 I0 U5 h2 n: P2 W0 e! O7 E; I JDEA:= EMA(DIF,9);
: e( a! Y/ q0 W7 `4 X4 U2 x) K% h- Q& S0 K! qMACD:= (DIF-DEA)*2;0 k j* s7 u7 G$ m5 K4 a: g! B
1 P% I" W. s6 X0 z8 a0 j; f+ U9 w6 D
: t5 S" i! ~: F1 A+ ^9 j均值:= SUM(ABS(MACD), 100)/100;2 O! h& _* C/ f+ \: n
8 E2 t, R. S" M1 H' M3 C$ S _# z起死回生:= REF(MACD, 2) > REF(MACD, 1) AND REF(MACD, 1) < 均值*0.1 AND 7 @" T2 H, j$ Z! w
1 U& k# a6 ?( n% C4 N7 _4 h6 z3 q, C+ W REF(MACD, 1)>=0 AND REF(MACD, 1) < MACD;
Q5 L/ X& |( z$ {" a1 }' w0 e" ^+ E; z% P( f$ m9 A# D; Y金叉失败:= REF(MACD, 2) < REF(MACD, 1) AND REF(MACD, 1) > 0-均值*0.1 AND * r! R! C! b9 Y$ q# r. K+ f
# M' L5 M# E0 n REF(MACD, 1)<=0 AND REF(MACD, 1) > MACD;5 P+ y8 L6 O: w! I& q7 z6 G7 n. y4 [8 ~0 \
; f0 Q8 i& x4 |0 [ {3 I% x( w7 ~0 g% ?. C; f) rAA1A:= BARSLAST(CROSS(DEA, DIF))+1;8 y/ f. e# m4 T: F* ~5 R
8 U9 {% z- s. N: Q, ~- }! s+ m8 F0 ^! ^ AA1B:= IF(起死回生 OR 金叉失败, BARSLAST(起死回生 OR 金叉失败)+3, 99999);- b! S& h/ k8 E9 s
; o/ C" a4 w& G8 M AA1:= IF(AA1B<AA1A, AA1B, AA1A);( O( ]$ T5 I4 X& I" x
9 S2 A8 z1 D7 @" @. C. j' l
" c5 e4 ^' U# s# q ^8 ~2 l7 }AA2A:= REF(BARSLAST(CROSS(DEA, DIF)), AA1)+1;
6 M7 J) }! v. F4 ^- `* H- _: C7 O$ r5 V8 BAA2B:= IF(REF(起死回生 OR 金叉失败, AA1), REF(BARSLAST(起死回生 OR 金叉失败), AA1), 99999)+3;! I7 s) L1 }* S" o% w
& ?5 z# J% X- i; N+ C2 C AA2:= IF(AA2B<AA2A, AA2B, AA2A);- w' q5 U6 ^0 `+ ?8 \0 j
2 z# P! X W+ l6 W$ ]& B: ?5 i% U9 f: I" l
( C# I i! z6 t% p1 ^+ rDIFZ~小值:= LLV(DIF, AA1+AA2);
. l9 z5 p2 w4 j" S$ V+ m$ F4 c3 f- N+ A3 `% ~! nDIFZ~小日:= LLVBARS(DIF, AA1+AA2);
) c l( S+ j* I P2 X8 H8 D8 O3 c2 c8 Q7 f% ], Q GDBL1:= IF(DIFZ~小日<=AA1, 0, 1);( }" V. \# s8 U' Z7 b4 c
6 ?) D& A: m, `: d6 x6 cDBL2:= IF(DBL1=1 AND C<REF(C, DIFZ~小日) AND DIF>REF(DIF, DIFZ~小日), 1, 0);3 g* Q# }$ r: x: Y& O, ]# N& d6 T0 z2 F8 \% x
DBL:= IF(DBL1=0, 0, DBL2);
! D3 ~" o* ]8 k# e$ ?7 Q* V3 c0 b5 g5 ?# e$ S$ V. @& H4 u3 x- \$ e$ K( r! H) t
DBLJC: DBL AND (CROSS(DIF, DEA) OR 起死回生) AND DIF>REF(DIF, 1);
|
|