当前位置:→ 公式网 > 大智慧公式 > 正文 ℃ 公式解密、改选股等业务 联系点击查看详情...
以下是两线指标(源码,贴图,说明)(无源码的请下载附件导入)
KDJ优化版
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:3*K-2*D;
买:J>REF(J,1) AND K>20 AND REF(J,1)<0,LINETHICK0;
DRAWICON(买,0,7),ALIGN1,LAYER0;
低位金叉:CROSS(K,D) AND REF(K,1)<25,LINETHICK0;
DRAWICON(低位金叉,0,1),ALIGN1,LAYER0;
A2:=BARSLAST(ref(cross(k,d),1));
B2:=ref(c,A2+1)>c and ref(k,A2+1)<k and cross(k,d);
KDJ底背离:FILTER(B2>0,5),linethick0,COLORYELLOW;
DRAWTEXT(FILTER(B2>0,5),0.80,'离'),COLORYELLOW;
MA4:=ma(c,30);
准:IF(买 AND MA4>REF(MA4,1),30,0),LINETHICK0;
DRAWTEXT(准,D,'准'),COLOR00FF00;
DOWN:=OPEN>CLOSE;
{去停牌和ST股}
ST:=STRFIND(stkname,'ST',1)>0;
S:=STRFIND(stkname,'S',1)>0;
股价偏离:=(c/ref(c,4)-1)*100<-20 and O/REF(LOW,1)<1.01 and COUNT(DOWN,3)=3 AND not(ST) and not(S);
aa:=HHV(股价偏离 ,5 );
杀跌:if(aa>0 and c>o,100,0),LINETHICK0;
VERTLINE(杀跌,1);
MID:=MA(J,20);
上轨:MID + 2*STD(J,20),COLOR993300;
下轨:MID - 2*STD(J,20),COLOR993300;
中轨:((上轨-下轨)/2)+下轨,COLOR993300;
抄:CROSS(J,下轨) AND J>REF(J,1),LINETHICK0;
DRAWTEXT(抄,下轨,'抄'),COLOR00FF00;
rsi 优化版
LC := REF(CLOSE,1);
RSI1:SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
RSI2:=SMA(MAX(CLOSE-LC,0),12,1)/SMA(ABS(CLOSE-LC),12,1)*100;
RSI3:=SMA(MAX(CLOSE-LC,0),24,1)/SMA(ABS(CLOSE-LC),24,1)*100;
A3:=BARSLAST(ref(cross(RSI1,RSI2),1));
B3:=ref(c,A3+1)>c and ref(RSI1,A3+1)<RSI1 and cross(RSI1,RSI2);
RSI底背离:FILTER(B3>0,5),linethick0,COLORCYAN;
STICKLINE(FILTER(B3>0,5),0,20,3,0),COLORCYAN;
DRAWTEXT(FILTER(B3>0,5),20,'RSI底背离'),COLORCYAN;
C3:=BARSLAST(ref(cross(RSI2,RSI1),1));
D3:=ref(c,C3+1)<c and ref(RSI1,C3+1)>RSI1 and cross(RSI2,RSI1);
DRAWTEXT(FILTER(D3>0,5),80,'RSI顶背离'),COLORMAGENTA;
R:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;;
MAR:=MA(R,3);
F:=100*(C-REF(C,1))/REF(C,1);
HHH:=EMA(R,25)+6;
买:(REF(R,2)>REF(R,3) AND REF(R,2)>REF(R,1) AND R>REF(R,1)
AND MAR>REF(MAR,1)+1 AND REF(MAR,2)-REF(MAR,1)>-1
AND REF(R,1)<REF(MAR,1) AND REF(R,2)-REF(MAR,2)>-3
AND REF(R,1)<38 AND R<HHH AND F<8),LINETHICK0;
DRAWICON(买,RSI1,7),ALIGN1,LAYER0;
秒进:if(H=O AND C=H AND H=L AND O>(REF(C,1)*1.04),100,0),LINETHICK0;
VERTLINE(秒进,1);
MID:=MA(RSI1,20);
上轨:MID + 2*STD(RSI1,20),COLOR993300;
下轨:MID - 2*STD(RSI1,20),COLOR993300;
中轨:((上轨-下轨)/2)+下轨,COLOR993300;
抄:CROSS(RSI1,下轨) AND RSI1>REF(RSI1,1),LINETHICK0;
DRAWTEXT(抄,下轨,'抄'),COLOR00FF00;