烦请老师再俢改指标 [博易POBO]
咨询内容:
HH1:=IFELSE(H<REF(H,1)&&REF(H,1)<REF(H,2),REF(H,2),0);
LL1:=IFELSE(L>REF(L,1)&&REF(L,1)>REF(L,2),REF(L,2),0);
HH2:=VALUEWHEN(HH1>0,HH1);
LL2:=VALUEWHEN(LL1>0,LL1);
K1:=IFELSE(CLOSE>HH2,-3,IFELSE(CLOSE<LL2,1,0));
K2:=VALUEWHEN(K1<>0,K1);
G:=IFELSE(K2=1,HH2,LL2);
G1:=VALUEWHEN(ISLASTBAR,G);
DRAWNUMBER(L>0,G1,G1,0,COLORCYAN);
W1:=K2;
W2:=OPEN-CLOSE;
HT:=IFELSE(OPEN>CLOSE,OPEN,CLOSE);
LT:=IFELSE(OPEN<CLOSE,OPEN,CLOSE);
DRAWCOLORKLINE( C<O,RGB(192,192,192),0);
DRAWCOLORKLINE(C>=O,RGB(192,192,192),1);
DRAWLINE(W1=1&&REF(W1,1)=1,G,W1=1&&REF(W1,1)=1,REF(G,1),COLORGREEN);
DRAWLINE(W1=-3&&REF(W1,1)=-3,G,W1=-3&&REF(W1,1)=-3,REF(G,1),COLORYELLOW);
DRAWSL(K2=1,G,0,1,0,COLORGREEN);
DRAWSL(K2=-3,G,0,1,0,COLORYELLOW);
BAA:=1;
MA4:=EMA(CLOSE,10)*BAA;
HH:=HHV(HIGH,5)*BAA;
LL:=LLV(LOW,5)*BAA;
H1:=IFELSE(CLOSE>REF(HH,1),1,0)*BAA;
L1:=IFELSE(CLOSE<REF(LL,1),-1,0)*BAA;
H0:=REF(HIGH,1)*BAA;
L0:=REF(LOW,1)*BAA;
P7:=H1+L1*BAA;
P8:=IFELSE(P7=0,REF(P7,1),P7)*BAA;
P9:=IFELSE(P8=0,REF(P8,1),P8)*BAA;
P10:=IFELSE(P9=0,REF(P9,1),P9)*BAA;
P11:=IFELSE(P10=0,REF(P10,1),P10)*BAA;
P12:=IFELSE(P11=0,REF(P11,1),P11)*BAA;
P13:=IFELSE(P12=0,REF(P12,1),P12)*BAA;
P14:=IFELSE(P13=0,REF(P13,1),P13)*BAA;
P15:=IFELSE(P14=0,REF(P14,1),P14)*BAA;
P16:=IFELSE(P15=0,REF(P15,1),P15)*BAA;
P17:=IFELSE(P16=0,REF(P16,1),P16)*BAA;
P18:=IFELSE(P17=0,REF(P17,1),P17)*BAA;
P19:=IFELSE(P18=0,REF(P18,1),P18)*BAA;
P20:=IFELSE(P19=0,REF(P19,1),P19)*BAA;
P21:=IFELSE(P20=0,REF(P20,1),P20)*BAA;
P22:=IFELSE(P21=0,REF(P21,1),P21)*BAA;
P23:=IFELSE(P22=0,REF(P22,1),P22)*BAA;
P24:=IFELSE(P23=0,REF(P23,1),P23)*BAA;
P25:=IFELSE(P24=0,REF(P24,1),P24)*BAA;
P26:=IFELSE(P25=0,REF(P25,1),P25)*BAA;
P27:=IFELSE(P26=0,REF(P26,1),P26)*BAA;
P28:=IFELSE(P27=0,REF(P27,1),P27)*BAA;
P29:=IFELSE(P28=0,REF(P28,1),P28)*BAA;
P30:=IFELSE(P29=0,REF(P29,1),P29)*BAA;
T:=IFELSE(P30=0,REF(P30,1),P30)*BAA;
//T=1,BPK;
//T=-1,SPK;
AUTOFILTER;
DD:=BARSLAST(CROSS(T=1,0.5));
KK:=BARSLAST(CROSS(T=-1,0.5));
DRAWLINE(W1=1 AND KK<DD,HIGH,W1=1 AND KK<DD,HT,COLORCYAN);
DRAWLINE(W1=1 AND KK<DD,LOW,W1=1 AND KK<DD,LT,COLORCYAN);
DRAWLINE(W1=-3 AND DD<KK,HIGH,W1=-3 AND DD<KK,HT,COLORRED);
DRAWLINE(W1=-3 AND DD<KK,LOW,W1=-3 AND DD<KK,LT,COLORRED);
STICKLINE(W1>0 AND KK<DD,OPEN,CLOSE,COLORCYAN,1);
STICKLINE(W1<=0 AND DD<KK,OPEN,CLOSE,COLORRED,1);
STICKLINE(W2>0&&W1<=0 AND DD<KK,OPEN,CLOSE,COLORRED,0);
STICKLINE(W2>0&&W1>0 AND KK<DD,OPEN,CLOSE,COLORCYAN,0);
N1:=7;
N2:=14;
LC := REF(CLOSE,1);//前一周期收盘价
RSI1:=SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100;//
RSI2:=SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100;//
SHORT:=12;
LONG:=26;
M:=9;
DIFF :=EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);//短周期与长周期的收盘价的指数平滑移动平均值做差。
DEA :=EMA(DIFF,M);
V1:=LLV(LOW,10);
V2:=HHV(H,25);
价位线:=EMA((C-V1)/(V2-V1)*4,4);
//DRAWTEXT(CROSS(3.5,价位线),90,'高●'),COLORFFFFFF;
VV1:=(C*2+H+L)/4*10;
VV2:=EMA(VV1,13)-EMA(VV1,34);
VV3:=EMA(VV2,5);
VV4:=2*(VV2-VV3)*5.5;
主力撤:=IF(VV4<=0,VV4,0);
主力进:=IF(VV4>=0,VV4,0);
V11:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1),3,1);
趋势线:=EMA(V11,3);
V12:=(趋势线-REF(趋势线,1))/REF(趋势线,1)*100;
买入:=趋势线<=13 AND V12>13;
BB:= (趋势线<=13 AND V12>13) AND FILTER((趋势线<=13 AND V12>13),10) ;
逃顶:=FILTER(趋势线>90 AND 趋势线<REF(趋势线,1) AND 主力进<REF(主力进,1),8);
KD1:=CROSS(T=1,0.5) AND W1=-3 AND DD<KK;
KD2:=(W1=-3 AND DD<KK AND DIFF>DEA AND RSI1>RSI2);
PK1:=CROSS(T=-1,0.5) AND W1=1 AND KK<DD;
PK2:=W1=1 AND KK<DD AND DIFF<DEA AND RSI1<RSI2;
KDD:=BARSLAST(CROSS(W1=-3 AND DD<KK,0.5))+1;
PKK:=BARSLAST(CROSS(W1=1 AND KK<DD,0.5))+1;
DD11:=(CROSS(COUNT(KD1 OR KD2,KDD)=1,0.5) OR KD1);
T1:=CROSS(3.5,价位线) AND (DIFF<DEA OR RSI1<RSI2);
T2:=逃顶 AND (DIFF<DEA OR RSI1<RSI2);
T3:=NOT( W1=-3 AND DD<KK) AND REF(W1=-3 AND DD<KK,1);
T31:=CROSS(DIFF<DEA AND RSI1<RSI2,0.5);
T4:=CROSS(COUNT(T1 OR T2 OR T3 OR T31,BARSLAST(DD11)+1)=1 ,0.5);
KK11:=(CROSS(COUNT(PK1 OR PK2,PKK)=1,0.5) OR PK1);
S1:=CROSS(价位线,0.3) AND (DIFF>DEA OR RSI1>RSI2);
S2:=BB AND (DIFF>DEA OR RSI1>RSI2);
S3:=NOT( W1=1 AND DD>KK) AND REF(W1=1 AND DD>KK,1);
S31:=CROSS(DIFF>DEA AND RSI1>RSI2,0.5);
S4:=CROSS(COUNT(S1 OR S2 OR S3 OR S31,BARSLAST(KK11)+1)=1 ,0.5);
MA20:=EMA(CLOSE,20);
M1:=MA(CLOSE,5);
M2:=MA(CLOSE,20),COLORYELLOW;
ZYZS:=IFELSE((M1 > M2),M2,M1),COLORGREEN;
KTEXT( NOT(ZYZS > REF(ZYZS,1) && ZYZS = M2),0 , MA20, 1,COLORGREEN,'←');
KTEXT( ZYZS > REF(ZYZS,1) && ZYZS = M2,0 , MA20,1 , COLORYELLOW,'→');
烦请老师改一下呀 您好,公式比较多的函数不匹配,无法修改。 来源 程序化久久网
烦请老师再俢改指标
以下是文华主图, 烦请老师改成博易 谢了HH1:=IFELSE(H<REF(H,1)&&REF(H,1)<REF(H,2),REF(H,2),0);
LL1:=IFELSE(L>REF(L,1)&&REF(L,1)>REF(L,2),REF(L,2),0);
HH2:=VALUEWHEN(HH1>0,HH1);
LL2:=VALUEWHEN(LL1>0,LL1);
K1:=IFELSE(CLOSE>HH2,-3,IFELSE(CLOSE<LL2,1,0));
K2:=VALUEWHEN(K1<>0,K1);
G:=IFELSE(K2=1,HH2,LL2);
G1:=VALUEWHEN(ISLASTBAR,G);
DRAWNUMBER(L>0,G1,G1,0,COLORCYAN);
W1:=K2;
W2:=OPEN-CLOSE;
HT:=IFELSE(OPEN>CLOSE,OPEN,CLOSE);
LT:=IFELSE(OPEN<CLOSE,OPEN,CLOSE);
DRAWCOLORKLINE( C<O,RGB(192,192,192),0);
DRAWCOLORKLINE(C>=O,RGB(192,192,192),1);
DRAWLINE(W1=1&&REF(W1,1)=1,G,W1=1&&REF(W1,1)=1,REF(G,1),COLORGREEN);
DRAWLINE(W1=-3&&REF(W1,1)=-3,G,W1=-3&&REF(W1,1)=-3,REF(G,1),COLORYELLOW);
DRAWSL(K2=1,G,0,1,0,COLORGREEN);
DRAWSL(K2=-3,G,0,1,0,COLORYELLOW);
BAA:=1;
MA4:=EMA(CLOSE,10)*BAA;
HH:=HHV(HIGH,5)*BAA;
LL:=LLV(LOW,5)*BAA;
H1:=IFELSE(CLOSE>REF(HH,1),1,0)*BAA;
L1:=IFELSE(CLOSE<REF(LL,1),-1,0)*BAA;
H0:=REF(HIGH,1)*BAA;
L0:=REF(LOW,1)*BAA;
P7:=H1+L1*BAA;
P8:=IFELSE(P7=0,REF(P7,1),P7)*BAA;
P9:=IFELSE(P8=0,REF(P8,1),P8)*BAA;
P10:=IFELSE(P9=0,REF(P9,1),P9)*BAA;
P11:=IFELSE(P10=0,REF(P10,1),P10)*BAA;
P12:=IFELSE(P11=0,REF(P11,1),P11)*BAA;
P13:=IFELSE(P12=0,REF(P12,1),P12)*BAA;
P14:=IFELSE(P13=0,REF(P13,1),P13)*BAA;
P15:=IFELSE(P14=0,REF(P14,1),P14)*BAA;
P16:=IFELSE(P15=0,REF(P15,1),P15)*BAA;
P17:=IFELSE(P16=0,REF(P16,1),P16)*BAA;
P18:=IFELSE(P17=0,REF(P17,1),P17)*BAA;
P19:=IFELSE(P18=0,REF(P18,1),P18)*BAA;
P20:=IFELSE(P19=0,REF(P19,1),P19)*BAA;
P21:=IFELSE(P20=0,REF(P20,1),P20)*BAA;
P22:=IFELSE(P21=0,REF(P21,1),P21)*BAA;
P23:=IFELSE(P22=0,REF(P22,1),P22)*BAA;
P24:=IFELSE(P23=0,REF(P23,1),P23)*BAA;
P25:=IFELSE(P24=0,REF(P24,1),P24)*BAA;
P26:=IFELSE(P25=0,REF(P25,1),P25)*BAA;
P27:=IFELSE(P26=0,REF(P26,1),P26)*BAA;
P28:=IFELSE(P27=0,REF(P27,1),P27)*BAA;
P29:=IFELSE(P28=0,REF(P28,1),P28)*BAA;
P30:=IFELSE(P29=0,REF(P29,1),P29)*BAA;
T:=IFELSE(P30=0,REF(P30,1),P30)*BAA;
//T=1,BPK;
//T=-1,SPK;
AUTOFILTER;
DD:=BARSLAST(CROSS(T=1,0.5));
KK:=BARSLAST(CROSS(T=-1,0.5));
DRAWLINE(W1=1 AND KK<DD,HIGH,W1=1 AND KK<DD,HT,COLORCYAN);
DRAWLINE(W1=1 AND KK<DD,LOW,W1=1 AND KK<DD,LT,COLORCYAN);
DRAWLINE(W1=-3 AND DD<KK,HIGH,W1=-3 AND DD<KK,HT,COLORRED);
DRAWLINE(W1=-3 AND DD<KK,LOW,W1=-3 AND DD<KK,LT,COLORRED);
STICKLINE(W1>0 AND KK<DD,OPEN,CLOSE,COLORCYAN,1);
STICKLINE(W1<=0 AND DD<KK,OPEN,CLOSE,COLORRED,1);
STICKLINE(W2>0&&W1<=0 AND DD<KK,OPEN,CLOSE,COLORRED,0);
STICKLINE(W2>0&&W1>0 AND KK<DD,OPEN,CLOSE,COLORCYAN,0);
N1:=7;
N2:=14;
LC := REF(CLOSE,1);//前一周期收盘价
RSI1:=SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100;//
RSI2:=SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100;//
SHORT:=12;
LONG:=26;
M:=9;
DIFF :=EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);//短周期与长周期的收盘价的指数平滑移动平均值做差。
DEA :=EMA(DIFF,M);
V1:=LLV(LOW,10);
V2:=HHV(H,25);
价位线:=EMA((C-V1)/(V2-V1)*4,4);
//DRAWTEXT(CROSS(3.5,价位线),90,'高●'),COLORFFFFFF;
VV1:=(C*2+H+L)/4*10;
VV2:=EMA(VV1,13)-EMA(VV1,34);
VV3:=EMA(VV2,5);
VV4:=2*(VV2-VV3)*5.5;
主力撤:=IF(VV4<=0,VV4,0);
主力进:=IF(VV4>=0,VV4,0);
V11:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1),3,1);
趋势线:=EMA(V11,3);
V12:=(趋势线-REF(趋势线,1))/REF(趋势线,1)*100;
买入:=趋势线<=13 AND V12>13;
BB:= (趋势线<=13 AND V12>13) AND FILTER((趋势线<=13 AND V12>13),10) ;
逃顶:=FILTER(趋势线>90 AND 趋势线<REF(趋势线,1) AND 主力进<REF(主力进,1),8);
KD1:=CROSS(T=1,0.5) AND W1=-3 AND DD<KK;
KD2:=(W1=-3 AND DD<KK AND DIFF>DEA AND RSI1>RSI2);
PK1:=CROSS(T=-1,0.5) AND W1=1 AND KK<DD;
PK2:=W1=1 AND KK<DD AND DIFF<DEA AND RSI1<RSI2;
KDD:=BARSLAST(CROSS(W1=-3 AND DD<KK,0.5))+1;
PKK:=BARSLAST(CROSS(W1=1 AND KK<DD,0.5))+1;
DD11:=(CROSS(COUNT(KD1 OR KD2,KDD)=1,0.5) OR KD1);
T1:=CROSS(3.5,价位线) AND (DIFF<DEA OR RSI1<RSI2);
T2:=逃顶 AND (DIFF<DEA OR RSI1<RSI2);
T3:=NOT( W1=-3 AND DD<KK) AND REF(W1=-3 AND DD<KK,1);
T31:=CROSS(DIFF<DEA AND RSI1<RSI2,0.5);
T4:=CROSS(COUNT(T1 OR T2 OR T3 OR T31,BARSLAST(DD11)+1)=1 ,0.5);
KK11:=(CROSS(COUNT(PK1 OR PK2,PKK)=1,0.5) OR PK1);
S1:=CROSS(价位线,0.3) AND (DIFF>DEA OR RSI1>RSI2);
S2:=BB AND (DIFF>DEA OR RSI1>RSI2);
S3:=NOT( W1=1 AND DD>KK) AND REF(W1=1 AND DD>KK,1);
S31:=CROSS(DIFF>DEA AND RSI1>RSI2,0.5);
S4:=CROSS(COUNT(S1 OR S2 OR S3 OR S31,BARSLAST(KK11)+1)=1 ,0.5);
MA20:=EMA(CLOSE,20);
M1:=MA(CLOSE,5);
M2:=MA(CLOSE,20),COLORYELLOW;
ZYZS:=IFELSE((M1 > M2),M2,M1),COLORGREEN;
KTEXT( NOT(ZYZS > REF(ZYZS,1) && ZYZS = M2),0 , MA20, 1,COLORGREEN,'←');
KTEXT( ZYZS > REF(ZYZS,1) && ZYZS = M2,0 , MA20,1 , COLORYELLOW,'→');
来源:程序化99网( WWW.CXH99.COM )
博易技术人员:烦请老师改一下呀 您好,公式比较多的函数不匹配,无法修改。 来源 程序化久久网
有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友
可联系技术人员 QQ: 262069696 或微信号:cxh99cxh99 进行 有偿收费 编写!
(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)
相关文章
-
没有相关内容