最新公告
  • 欢迎您光临九毛八公式指标网www.9m8.cn,本站全新改版试运行,期间内容全部免费,欢迎下载!欢迎加入本站VIP
  • 通达信KDJ背离选股指标公式

    正文概述    2024-05-04 04:02:20  
    j1:=(100); 预设:=80; RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100; K:SMA(RSV,3,1),LINETHICK0,PRECIS1; D:SMA(K,3,1),LINETHICK0,PRECIS1; J:3*K-2*D,LINETHICK0,PRECIS1; RSV1:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9)); RSV2:=(RSV1-0.5)/5*EMA(C,21); RSVK:=SMA(RSV2,3,1); RSVD:=SMA(RSVK,3,1); RSVJ:=RSVK*3-RSVD*2; Kj:RSVK+EMA(C,21),COLORWHITE,LINETHICK1,PRECIS0; Dj:RSVD+EMA(C,21),COLORYELLOW,LINETHICK1; Jj:RSVJ+EMA(C,21),COLORRED; LC:=REF(CLOSE,1); Aa1:=SMA(MAX(CLOSE-LC,0),6,1); Bb1:=SMA(ABS(CLOSE-LC),6,1); RSI:aa1/bb1*100,LINETHICK0,PRECIS1; TYP:=(HIGH+LOW+CLOSE)/3; :(TYP-MA(TYP,14))/(0.015*AVEDEV(TYP,14)),LINETHICK0,PRECIS1; 买:=(cci -80andcci ref(cci,1))and(rsi 40andrsi ref(rsi,1))and(j 20)andj DRAWTEXT(买,L-0.01,'●买'),COLORMAGENTA; 卖:=(cci 90andcci ref(cci,1))and(rsi 60andrsi ref(rsi,1))and(j 80andj ref(j,1)); 卖21:=ref(cci,1) 100andref(rsi,1) 70andref(j,1) 90and(cci ref(cci,1)orrsi ref(rsi,1)orj ref(j,1)); 卖22:=cci 100andj 90andrsi 70and(cci ref(cci,1)orrsi ref(rsi,1)orj ref(j,1)); 卖2:=卖21or卖22; DRAWTEXT(卖,h+0.1,'●'),colorgreen; DRAWTEXT(卖2,h+0.05,'●'),Coloryellow; {j反推} j11:=j; j昨:=ref(j,1); jx:=if(j1=-50,j11,if(j1=-49,j昨,j1)); xxx:=((9/7*jx-2*ref(k,1)+12/7*ref(d,1))/100)*(HHV(HIGH,9)-LLV(LOW,9))+LLV(LOW,9); YCJ:IF(C LC,(REF(Aa1,1)*(9-1)-REF(Bb1,1)*(9-1)*RSI预设/100)/(RSI预设/100-1)+LC,LC+REF(Bb1,1)*(9-1)-REF(Aa1,1)*(9-1)/(RSI预设/100)),LINETHICK0,PRECIS1; rYCJ:=(YCJ-ref(c,1)); rre:=(80-ref(rsi,1)); rzz:=rre/rycj; rh:=h-ref(c,1); rhh:rzz*rh+ref(rsi,1),LINETHICK0,PRECIS1; jxxx:=(xxx-ref(c,1)); jje:=(100-ref(j,1)); jzz:=jje/jxxx; jhh:jzz*rh+ref(j,1),LINETHICK0,PRECIS1; xh:=(rhh 70andjhh 100)or(rhh 80andjhh jrhh:=xhand(j jhhorrsi rhh); DRAWTEXT(jrhh,h+0.1,'◆'),colorred; DRAWTEXTREL(450,30,'预设J值=100J临界股价:'+NUMTOSTRN(xxx,2)),LINETHICK1,Coloryellow; DRAWTEXTREL(450,90,'预设R值=80R临界股价:'+NUMTOSTRN(YCJ,2)),LINETHICK1,Coloryellow; DRAWTEXTABS(10,10,'图示:●=必卖'),LINETHICK1,colorgreen; DRAWTEXTABS(10,30,'图示:●=指标应卖'),LINETHICK1,Coloryellow; DRAWTEXTABS(10,50,'图示:◆=指标超卖'),LINETHICK1,colorred; DIF:(EMA(CLOSE,12)-EMA(CLOSE,26)),colorwhite; DEA:EMA(DIF,9),coloryellow; MACD:(DIF-DEA)*2,COLORSTICK; 死叉:=CROSS(DEA,DIF); N1:=BARSLAST(死叉); N2:=REF(BARSLAST(死叉),N1+1); N3:=REF(BARSLAST(死叉),N2+N1+2); CL1:=LLV(C,N1+1); DIFL1:=LLV(DIF,N1+1); CL2:=REF(CL1,N1+1); DIFL2:=REF(DIFL1,N1+1); CL3:=REF(CL2,N1+1); DIFL3:=REF(DIFL2,N1+1); PDIFL2:=IF(DIFL2 0,INTPART(LOG(DIFL2))-1,INTPART(LOG(-DIFL2))-1); MDIFL2:=INTPART(DIFL2/POW(10,PDIFL2)); PDIFL3:=IF(DIFL3 0,INTPART(LOG(DIFL3))-1,INTPART(LOG(-DIFL3))-1); MDIFL3:=INTPART(DIFL3/POW(10,PDIFL3)); MDIFB2:=INTPART(DIF/POW(10,PDIFL2)); MDIFB3:=INTPART(DIF/POW(10,PDIFL3)); 直接底背离:=(CL1MDIFL2)AND(MACD 0ANDREF(MACD,1) 0)ANDMDIFB2 =REF(MDIFB2,1); 隔峰底背离:=(CL1MDIFL3)AND(MACD 0ANDREF(MACD,1) 0)ANDMDIFB3 =REF(MDIFB3,1); B:=(直接底背离OR隔峰底背离); BG:=((MDIFB2 REF(MDIFB2,1))*REF(直接底背离,1))OR((MDIFB3 REF(MDIFB3,1))*REF(隔峰底背离,1)); STICKLINE(BORBG,0,MACD,8,0),colorgreen; DRAWTEXT(FILTER(BG,10),(DIF*1.5),'底'),colorred; :=CROSS(DIF,DEA); M1:=BARSLAST(金叉); M2:=REF(BARSLAST(金叉),M1+1); M3:=REF(BARSLAST(金叉),M2+M1+2); CH1:=HHV(C,M1+1); DIFH1:=HHV(DIF,M1+1); CH2:=REF(CH1,M1+1); DIFH2:=REF(DIFH1,M1+1); CH3:=REF(CH2,M1+1); DIFH3:=REF(DIFH2,M1+1); PDIFH2:=IF(DIFH2 0,INTPART(LOG(DIFH2))-1,INTPART(LOG(-DIFH2))-1); MDIFH2:=INTPART(DIFH2/POW(10,PDIFH2)); PDIFH3:=IF(DIFH3 0,INTPART(LOG(DIFH3))-1,INTPART(LOG(-DIFH3))-1); MDIFH3:=INTPART(DIFH3/POW(10,PDIFH3)); MDIFT2:=INTPART(DIF/POW(10,PDIFH2)); MDIFT3:=INTPART(DIF/POW(10,PDIFH3)); 直接顶背离:=(CH1 CH2)AND(MDIFT20ANDREF(MACD,1) 0)ANDMDIFT2 =REF(MDIFT2,1); 隔峰顶背离:=(CH1 CH3ANDCH3 CH2)AND(MDIFT30ANDREF(MACD,1) 0)ANDMDIFT3 =REF(MDIFT3,1); T:=(直接顶背离OR隔峰顶背离); TG:=((MDIFT2STICKLINE(TORTG,0,MACD,8,0),colorred; DRAWTEXT(FILTER(TG,20),(DIF*1.4),'顶'),colorgreen; A1:=REF(C,2) REF(O,2)ANDREF(C,2)/REF(O,2) 1.02; A2:=REF(H,1) REF(MAX(C,O),1)ANDREF(MIN(C,O),1) REF(L,1) ANDREF(MAX(C,O)/MIN(C,O) 1.01,1); A3:=C OANDMAX(C,O)/MIN(C,O) 1.03ANDC REF(O,1)ANDV REF(V,1) ANDC MA(C,60)ANDO REF(O,1); A4:=REF(C,2) REF(MAX(C,O),1)ANDREF(V,1) REF(V,2); XG:A1ANDA2ANDA3ANDA4;

    公式解读:

    九毛八公式指标,一个优质的公式指标平台!
    九毛八公式指标 » 通达信KDJ背离选股指标公式 加入收藏