求助老师给下面指标改成通达信版本可用,谢谢!
[通达信] MA5:=MA(r0,5); 超买:3.2,coloryellow; 超卖:0.5,coloryellow; 中位线:=1.75; 最小值:=LLV(LOW,10); 最大值:=HHV(HIGH,25); 波动线:=EMA((CLOSE-最小值)/(最大值-最小值)*4,4); 平均线:EMA(波动线,3); 主力攻击:=r0-(ABS(REF(r0,1))+ABS(REF(r0,2))+ABS(REF(r0,3))+ABS(REF(r0,4))+ABS(REF(r0,5))/2)>0 AND 平均线>=REF(平均线,1) AND REF(平均线,1)<REF(平均线,2); 主力撤退:=-((r0+(ABS(REF(r0,1))+ABS(REF(r0,2))+ABS(REF(r0,3))+ABS(REF(r0,4))+ABS(REF(r0,5))/2)<0) AND 平均线<=REF(平均线,1) AND REF(平均线,1)>REF(平均线,2)); DRAWTEXT(主力攻击>0,1.5,"主进"),colorred; DRAWTEXT(主力撤退<0,3,"主退"),colorgreen; 信息:=平均线>=REF(平均线,1); 走强:=CLOSE>MA(CLOSE,20)AND CLOSE>MA(CLOSE,5); 走弱:=CLOSE<MA(CLOSE,10)AND CLOSE<MA(CLOSE,5); 量:=VOL>MA(VOL,5); STICKLINE(平均线>=REF(平均线,1),波动线,REF(波动线,1),5,0),colorred; STICKLINE(平均线<REF(平均线,1),波动线 ,REF(波动线,1),5,0),colorgreen; d:=信息=1 AND REF(信息,1)=0 AND (REF(信息,2)+REF(信息,3)=0) AND 平均线<0.5; s:=信息=1 AND REF(信息,1)=0 AND (REF(信息,2)+REF(信息,3)=0) AND 走强=1 AND REF(走强,1)=0 AND 量=1; dd:=平均线>2 AND (信息=0 AND REF(信息,1)=1) AND (REF(信息,2)+REF(信息,3)=2); tz:=(信息=0 AND REF(信息,1)=1) AND (REF(信息,2)+REF(信息,3)=2) AND MA5<0 AND 走弱=1 AND 平均线>1; DRAWTEXT(d=1,平均线,'底'); DRAWTEXT(s=1,平均线,'升'); DRAWTEXT(dd=1,平均线,'顶'); DRAWTEXT(tz=1,平均线,'下'); PARTLINE(平均线,平均线>=REF(平均线,1),colorred,平均线<REF(平均线,1),colorgreen); ////马上成功//// Hua:=(CLOSE - LLV(LOW,14)) / (HHV(HIGH,14) - LLV(LOW,14)) * 1.2 * CLOSE; Nv1:=EMA(Hua,4); Nv2:=EMA(Hua,8); DRAWICON(CROSS(Nv1,Nv2) AND CLOSE/OPEN>1.05,0.5,1); DRAWICON(CROSS(Nv2,Nv1) AND COUNT(CROSS(Nv1,Nv2) AND CLOSE/OPEN>1.05 ,20) ,3.2,2); ////必涨之星//// Hua2:=SMA(MAX(CLOSE-REF(CLOSE,1),0),16,2)/SMA(ABS(CLOSE/REF(CLOSE,1)),16,2)*100; Xian=SMA(Hua2,3,1); Nv3:=SMA(Xian,3,1); XiNv=3*Xian-2*Nv3; 日:=-100;昨前:=-3; 高1:=-REF(-HHV(H,日),昨前); 低1:=-REF(-LLV(L,日),昨前); 低:=-REFDATE(低1,DATE),colorred,LINETHICK2; VARC:=-低+(低+OPEN); WR1:=-低-(HHV(HIGH,5)-CLOSE)/(HHV(HIGH,5)-LLV(LOW,5)); WR2:=-低+(HHV(HIGH,5)-CLOSE)/(HHV(HIGH,5)-LLV(LOW,5)); 买入条件:=CROSS(XiNv,Nv3),colorwhite; 卖出条件:=CROSS(Nv3,XiNv) ; DRAWICON( 卖出条件,3.3,2),coloryellow; DRAWICON(买入条件,0.4,1),colorwhite; AAA2:=SUM(IF( CLOSE>REF(CLOSE,1),VOL*C,0),0); AAA3:=SUM(IF( CLOSE<REF(CLOSE,1),VOL*C,0),0); AAA4:=SUM(IF( CLOSE=REF(CLOSE,1),VOL*C,0),0); BB1:=0; B1万元:=DVOL*DCLOSE/100; B1差:=B1万元-REF(B1万元,1); B2万元:=DVOL*DCLOSE/100; B2比:=B2万元/REF(B2万元,1); 净流入万元:=(AAA2-AAA3-0.5*AAA4); PM:=MA(净流入万元,1); PMA:=PM/REF(PM,1)>1; PMB:=REF(PMA,1)<1 AND PMA; 密码:=(EMA(MA(B1万元,2),2))/100000,coloryellow,NODRAW; 二日比:=密码/REF(密码,1); 选股:=PMB AND 密码>REF(密码,1) AND 二日比>1 ,colorred,NODRAW; 均价线:=AMOUNT/V/100; 均价线2:=EMA(均价线,3); 均价线5:=EMA(均价线,5); 均价线10:=EMA(均价线,10); 均价线30:=EMA(均价线,30); 突破:=C>均价线2 AND 均价线2<REF(均价线2,1) AND REF(均价线2,1)<REF(均价线2,2) AND REF(均价线2,2)<REF(均价线2,3) AND 选股; DRAWTEXT(突破,0.8,'必涨'),colorred; |