“防狼術(shù)”條件選股公式
一,MACD的DEA在0軸之上的選股公式:
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIF,9); RET:DEA>=0;
二,MACD的DEA剛上穿0軸的選股公式:
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIF,9); RET:DEA>=0 AND REF(DEA,1)<0;
三,MACD的DEA上穿零軸后,回調(diào)不破零軸選股公式:
{MACD的DEA上穿零軸后,回調(diào)不破零軸選股} DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIFF,9); MACD:=(DIFF-DEA)*2; 不破零軸:=DIFF>0 AND DEA>0; 上次零下金叉:=REF(DEA,BARSLAST(REF(CROSS(DIFF,DEA),1))+1)<0; 金叉:=CROSS(DIFF,DEA); 上穿零軸:=CROSS(DEA,0); 回調(diào):= MACD>REF(MACD,1) AND REF(MACD,1)<REF(MACD,2) AND REF(MACD,2)<REF(MACD,3); 第一種:=不破零軸 AND 回調(diào) AND MACD>0 AND 上次零下金叉;{DIFF與DEA收口后再?gòu)埧趠 第二種:=不破零軸 AND 回調(diào) AND MACD<0; 第三種:=不破零軸 AND 金叉 AND 上次零下金叉;{DIFF與DEA在0軸上死叉后,再次在0軸上第一次金叉} 選股:第一種 OR 第二種 OR 第三種;
四, 沿20日線(xiàn)上漲,股價(jià)回調(diào)不破20日線(xiàn)選股公式:
MA20:=MA(C,20); XG:COUNT(MA20>REF(MA20,1),3)=3 AND BETWEEN(L,MA20*0.98,MA20*1.02) AND C>=MA20;
五,股價(jià)在60日線(xiàn)之上,且5日線(xiàn)上交20日線(xiàn)選股公式:
C>MA(C,60) AND CROSS(MA(C,5),MA(C,20));
六,底分型選股公式:
V00:= HIGH<REF(HIGH,1) AND LOW<REF(LOW,1); V01:= HIGH<REF(HIGH,1) AND LOW>REF(LOW,1); V02:= HIGH>REF(HIGH,1) AND LOW<REF(LOW,1); V03:= HIGH>REF(HIGH,1) AND LOW>REF(LOW,1); V04:= REF(HIGH,2) < HIGH AND REF(LOW,2) < LOW AND REF(HIGH,2) > REF(HIGH,1) AND REF(LOW,2) < REF(LOW,1); V1:= COUNT(V00,6)>=3 AND COUNT(V01 OR V02,5)=0 AND LLVBARS(LOW,6) = 1 AND HHVBARS(HIGH,6) >= 5 AND V03; V2:= COUNT(V00,7)>=3 AND COUNT(V01 OR V02,6)=1 AND LLVBARS(LOW,7) = 2 AND HHVBARS(HIGH,7) >= 6 AND V04; V3:= COUNT(V00,7)>=3 AND COUNT(V01 OR V02,6)=1 AND LLVBARS(LOW,7) = 1 AND HHVBARS(HIGH,7) >= 6 AND V03; V4:= COUNT(V00,8)>=3 AND COUNT(V01 OR V02,7)<=2 AND LLVBARS(LOW,8) = 2 AND HHVBARS(HIGH,8) >= 7 AND V04; V5:= COUNT(V00,8)>=3 AND COUNT(V01 OR V02,7)<=2 AND LLVBARS(LOW,8) = 1 AND HHVBARS(HIGH,8) >= 7 AND V03; V6:= COUNT(V00,9)>=3 AND COUNT(V01 OR V02,8)<=3 AND LLVBARS(LOW,9) = 2 AND HHVBARS(HIGH,9) >= 8 AND V04; V7:= COUNT(V00,9)>=3 AND COUNT(V01 OR V02,8)<=3 AND LLVBARS(LOW,9) = 1 AND HHVBARS(HIGH,9) >= 8 AND V03; V8:= COUNT(V00,10)>=3 AND COUNT(V01 OR V02,9)<=4 AND LLVBARS(LOW,10) = 2 AND HHVBARS(HIGH,10) >= 9 AND V04; V9:= COUNT(V00,10)>=3 AND COUNT(V01 OR V02,9)<=4 AND LLVBARS(LOW,10) = 1 AND HHVBARS(HIGH,10) >= 9 AND V03; V10:= COUNT(V00,11)>=3 AND COUNT(V01 OR V02,10)<=5 AND LLVBARS(LOW,11) = 2 AND HHVBARS(HIGH,11) >= 10 AND V04; XG: V1 OR V2 OR V3 OR V4 OR V5 OR V6 OR V7 OR V8 OR V9 OR V10;
七,三買(mǎi)點(diǎn)選股公式:
N1:=5;{最近下跌天數(shù)} N2:=31;{上漲天數(shù)} N3:=55;{平臺(tái)高點(diǎn)天數(shù)} LL:=LLV(L,N1); HH:=REF(HHV(H,N2),N1); H0:=REF(HHV(H,N3),N1+N2); ZF:=(C-REF(C,1))/REF(C,1)*100; 纏論三買(mǎi)點(diǎn):HH=HHV(H,N2+N1) AND LL>=H0 AND SUM(ZF>9.9,30)>1 OR SUM(ZF>8.9,30)>1;
--------------------------------------------------------------------------------
{三買(mǎi)選股公式2.5}
N1:=9;{最近下跌天數(shù)} N2:=30;{上漲天數(shù)} N3:=56;{平臺(tái)高點(diǎn)天數(shù)}
LL:=LLV(L,N1); HH:=HHV(H,2*N1); H0:=REF(HHV(H,N3),N1+N2);
選股:HH=HHV(H,N2+N1+N3) AND LL>H0 AND LL/HH<0.85; {創(chuàng)N2+N1+N3天新高,回調(diào)低點(diǎn)I不破前平臺(tái)高點(diǎn)(可根據(jù)自己要求適當(dāng)放寬到0.97),本次回調(diào)低點(diǎn)最低值與最高值下跌幅度不低于15%}; --------------------------------------------------------------------------------
{三買(mǎi)選股公式2.0}
N1:=5;{最近下跌天數(shù)} N2:=31;{上漲天數(shù)} N3:=55;{平臺(tái)高點(diǎn)天數(shù)}
LL:=LLV(L,N1); HH:=REF(HHV(H,N2),N1); H0:=REF(HHV(H,N3),N1+N2);
選股:HH=HHV(H,N2+N1+N3) AND LL>=0.97*H0 AND LL/HH<0.85; {創(chuàng)N2+N1+N3天新高,回調(diào)低點(diǎn)不低于前平臺(tái)高點(diǎn)(我適當(dāng)放寬到0.97,嚴(yán)格的朋友可自己調(diào)整),回調(diào)低點(diǎn)最低值與最高值下跌幅度不低于15%}; ----------------------------------------------------------------------------------
{三買(mǎi)選股公式1.0}
N1:=5;{最近下跌天數(shù)} N2:=31;{上漲天數(shù)} N3:=55;{平臺(tái)高點(diǎn)天數(shù)} LL:=LLV(L,N1); HH:=REF(HHV(H,N2),N1); H0:=REF(HHV(H,N3),N1+N2);
選股:HH=HHV(H,N2+N1) AND LL>=H0;
八,選股:EXPMA 5日與10日金叉并且第二天的收盤(pán)價(jià)在EXPMA的5日線(xiàn)以上. cross(ref(ema(c,5),1),ref(ema(c,10),1)) and c>ema(c,5);
九,股價(jià)上穿5周均線(xiàn):注意:選股時(shí)用周線(xiàn) xg:cross(c,ma(c,5));
|