您现在的位置:程序化交易>> 期货公式>> 文华财经>> 文华财经知识>>正文内容

运行不了,求老师修改一下 [文华财经]

  • 咨询内容:  {周氏CPXH2}
    {P5:=5;
    操:MA(CLOSE,P5),LINETHICK3,COLORFF0000,PRECIS1;
    PARTLINE(操>REF(操,1),操),COLOR00FFFF,LINETHICK3; }
    A:=MA(CLOSE,13)+ABS(MA(CLOSE,13)-REF(MA(CLOSE,13),1));
    B:=MA(CLOSE,13)+MA(CLOSE,13)-REF(MA(CLOSE,13),1);
    FSL:=IF(MA(CLOSE,13)<B,B,MA(CLOSE,13));
    CZ:=FSL-(EMA(C,3)-FSL),COLOR899995;
    PM:MA(C,5),COLORFF00FF,LINETHICK3;
    PARTLINE(PM>REF(PM,1),PM),COLOR00FFFF,LINETHICK3;
    PARTLINE(PM=REF(PM,1),PM),COLORRED,LINETHICK3;
    PARTLINE(PM<REF(PM,1),PM),COLORFF0000,LINETHICK3;

    {压1:HHV(OPEN,13),COLOR00FFFF,LINETHICK1;
    撑1:LLV(OPEN,13),COLOR00FFFF,LINETHICK1;}
    {HR:=HHV(HIGH,20);
    HRY:=LLV(LOW,20);
    HRY11:=HR*HRY;
    HRY33:SQRT(HRY11),COLORFFFFFF,LINETHICK2;
    {PARTLINE(C>HRY33 AND HRY33 >=REF(HRY33 ,1), HRY33 ),LINETHICK2,COLORFF00FF;}
    HH:=HHV(HIGH,11);
    LL:=LLV(LOW,11);
    HH1:=BARSLAST((HH>REF(HH,1)));
    LL1:=BARSLAST((LL<REF(LL,1)));
    A:=IF((HH1 < LL1),1,IFELSE((HH1 > LL1),-1,0));

    {STICKLINE(HH1<=LL1,O,C,4,0),COLOR1620A9;
    STICKLINE(HH1<=LL1,C,H,0.4,0),COLOR1620A9;
    STICKLINE(HH1<=LL1,L,O,0.4,0),COLOR1620A9;
    STICKLINE(HH1>LL1,O,C,4,0),COLOR11B87F;
    STICKLINE(HH1>LL1,C,H,0.4,0),COLOR11B87F;
    STICKLINE(HH1>LL1,L,O,0.4,0),COLOR11B87F;
    DRAWTEXT(CROSS(HH1,LL1),HH,'',COLORFFFFFF;
    DRAWTEXT(CROSS(LL1,HH1),LL,'',COLOR00FFFF;}

    {哭笑脸短}
    指:= EMA((EMA(CLOSE,4)+EMA(CLOSE,6)+EMA(CLOSE,12)+EMA(CLOSE,24))/4,2),COLORWHITE,LINETHICK1,PRECIS0;

    顶:=REFX(HIGH,5)<HIGH AND REFX(HIGH,4)<HIGH AND REFX(HIGH,3)<HIGH AND REFX(HIGH,2)<HIGH AND REFX(HIGH,1)<HIGH AND REF(HIGH,1)<HIGH AND REF(HIGH,2)<HIGH AND REF(HIGH,3)<HIGH AND REF(HIGH,4)<HIGH AND REF(HIGH,5)<HIGH;
    底:=REFX(LOW,5)>LOW AND REFX(LOW,4)>LOW AND REFX(LOW,3)>LOW AND REFX(LOW,2)>LOW AND REFX(LOW,1)>LOW AND REF(LOW,1)>LOW AND REF(LOW,2)>LOW AND REF(LOW,3)>LOW AND REF(LOW,4)>LOW AND REF(LOW,5)>LOW;
    DRAWICON(底,LOW,9);
    DRAWICON(顶,HIGH,10);

    {天门阵}

     L1:=LLV(HIGH,N);
     H1:=HHV(L,N);
     C1:=(H1+L1)/2;
     D1:=LLV(HIGH,M);
     价:=EMA((2*C+H+L)/4,M),COLORWHITE,LINETHICK0,PRECIS0;

    {短期信号}
    VA3:=DATE>901224 AND DATE<1281130;
    MID:=VA3*(3*CLOSE+LOW+OPEN+HIGH)/6;
    操盘线:=VA3*(20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210;

    角度:=ATAN((操盘线/REF(操盘线,1)-1)*100)*180/3.1416,LINETHICK0,COLORWHITE,PRECIS0;

    空头线:=VA3*EMA(操盘线,6);
    PARTLINE(空头线>操盘线,操盘线),LINETHICK4,COLORGREEN;
    PARTLINE(空头线<操盘线,操盘线),LINETHICK4,COLORRED;

    {波峰波谷}
    TY:=C;
    X:=8;
    A1:=REF(TY,X)=HHV(TY,2*X+1); B1:=FILTER(A1,X); C1E:=BACKSET(B1,X+1); HD:=FILTER(C1E,X);
    A2:=REF(TY,X)=LLV(TY,2*X+1); B2:=FILTER(A2,X); C2:=BACKSET(B2,X+1); LD:=FILTER(C2,X);
    AQ:=REF(C,BARSLAST(HD)); BQ:=REF(C,BARSLAST(LD));
    T1:=BARSLAST(HD)<BARSLAST(LD) AND NOT(HD) ;
    T2:=BARSLAST(HD)>BARSLAST(LD) AND NOT(LD);
    上:IF(T1,AQ,AQ),COLORFFF666,LINETHICK2;
    STICKLINE(T1,AQ,AQ,2,0),COLORFFFFFF;
    下:IF(T2,BQ,BQ),COLORFF999F,LINETHICK2;
    STICKLINE(T2,BQ,BQ,2,0),COLORFFFFFF;

    {哭笑脸长}
    {DRAWICON(CROSS(ZIG(3,5),REF(ZIG(3,5),1)),LOW*0.9985,14);
    DRAWICON(CROSS(REF(ZIG(3,5),1),ZIG(3,5)),HIGH*1.005,24);}

    KS:=(((CLOSE - EMA(CLOSE,8)) / EMA(CLOSE,8)) * (0 - 100));
    趋Q:=EMA(((KS / 5) + EMA(CLOSE,5)),3);
    AA:= - 100 * (趋Q - CLOSE) / 趋Q;
    XQ:=(((CLOSE/21) * 20) + CLOSE);
    Y:=EMA(CLOSE,10);
    LLQ:=REF(CLOSE,2);
    C1W:=(CLOSE+LOW+HIGH)/3;
    C2W:=EMA(C1W,6);
    C3W:=EMA(C2W,5);
    C4:=CROSS(C2W,C3W);
    {DRAWTEXT(C4,LOW/1.0002,'',COLOR00FFFF;
    C5:=CROSS(C3W,C2W);
    DRAWTEXT(C5,HIGH*1.001,'',COLORFFFFFF;}

    RSV:=(CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100;
    K:=SMA(RSV,3,1);
    D:=SMA(K,3,1);
    J:=3*K-2*D;
    RSV24:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100;
    K24:=SMA(RSV24,3,1);
    D24:=SMA(K24,3,1);
    J24:=3*K24-2*D24;
    阻:IF(CROSS(J24,J),HIGH,REF(HIGH,BARSLAST(CROSS(J24,J)))),POINTDOT,LINETHICK2,COLORFF0000,PRECIS1;

    HHQ:=HHV(HIGH,1)/5+HHV(HIGH,2)/5+HHV(HIGH,2)/5+HHV(HIGH,5)/5+HHV   (HIGH,8)/5;
    LLQ:=LLV(LOW,1)/5+LLV(LOW,2)/5+LLV(LOW,2)/5+LLV(LOW,5)/5+LLV(LOW,8)/5;
    H1Q:= IFELSE(H<REF(H,2)&&REF(H,1)<REF(H,2),REF(H,2),0);
    L1Q:= IFELSE(L>REF(L,2)&&REF(L,1)>REF(L,2),REF(L,2),0);
    H2Q:=VALUEWHEN(H1Q>0,H1Q);
    L2:=VALUEWHEN(L1Q>0,L1Q);
    K1:=IFELSE(CLOSE>H2Q,-3,IFELSE(CLOSE<L2,1,0));
    K2:=VALUEWHEN(K1<>0,K1);
    GG:=IFELSE(K2=1,H2Q,L2);
    GG1:=VALUEWHEN(ISLASTBAR,GG);
    TMP1:=K2;
    W1:=K2;
    W2:=OPEN-CLOSE;
    HT:=IFELSE(OPEN>CLOSE,OPEN,CLOSE);
    LT:=IFELSE(OPEN<CLOSE,OPEN,CLOSE);
    DRAWTEXT(CROSS(TMP1,0),HHQ,'↓',COLOR00FFFF;
    DRAWTEXT(CROSS(0,TMP1),LLQ,'↑',COLORYELLOW;
    OCH:=MAX(OPEN,CLOSE);
    OCL:=MIN(OPEN,CLOSE);

     

     来源:程序化99

  • 文华技术人员:  参考:

    AAA:=MA(CLOSE,13)+ABS(MA(CLOSE,13)-REF(MA(CLOSE,13),1)); B:=MA(CLOSE,13)+MA(CLOSE,13)-REF(MA(CLOSE,13),1); FSL:=IF(MA(CLOSE,13)<B,B,MA(CLOSE,13)); CZ:=FSL-(EMA(C,3)-FSL),COLOR899995; PM:MA(C,5),COLORFF00FF,LINETHICK3; PARTLINE1(PM>REF(PM,1),PM),COLOR00FFFF,LINETHICK3; PARTLINE1(PM=REF(PM,1),PM),COLORRED,LINETHICK3; PARTLINE1(PM<REF(PM,1),PM),COLORFF0000,LINETHICK3;

    HH:=HHV(HIGH,11); LL:=LLV(LOW,11); HH1:=BARSLAST((HH>REF(HH,1))); LL1:=BARSLAST((LL<REF(LL,1))); A:=IF((HH1 < LL1),1,IFELSE((HH1 > LL1),-1,0));


    {哭笑脸短} 指:= EMA((EMA(CLOSE,4)+EMA(CLOSE,6)+EMA(CLOSE,12)+EMA(CLOSE,24))/4,2),COLORWHITE,LINETHICK1,PRECIS0;
    顶:=REFX(HIGH,5)<HIGH AND REFX(HIGH,4)<HIGH AND REFX(HIGH,3)<HIGH AND REFX(HIGH,2)<HIGH AND REFX(HIGH,1)<HIGH AND REF(HIGH,1)<HIGH AND REF(HIGH,2)<HIGH AND REF(HIGH,3)<HIGH AND REF(HIGH,4)<HIGH AND REF(HIGH,5)<HIGH; 底:=REFX(LOW,5)>LOW AND REFX(LOW,4)>LOW AND REFX(LOW,3)>LOW AND REFX(LOW,2)>LOW AND REFX(LOW,1)>LOW AND REF(LOW,1)>LOW AND REF(LOW,2)>LOW AND REF(LOW,3)>LOW AND REF(LOW,4)>LOW AND REF(LOW,5)>LOW; DRAWICON(底,LOW,9); DRAWICON(顶,HIGH,10);
    N:=20; M:=10;
     L1:=LLV(HIGH,N);  H1:=HHV(L,N);  C1:=(H1+L1)/2;  D1:=LLV(HIGH,M);  价:=EMA((2*C+H+L)/4,M),COLORWHITE,LINETHICK1,PRECIS0;

    VA3:=1; MID:=VA3*(3*CLOSE+LOW+OPEN+HIGH)/6; 操盘线:=VA3*(20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210;
    角度:=ATAN((操盘线/REF(操盘线,1)-1)*100)*180/3.1416,LINETHICK1,COLORWHITE,PRECIS0;
    空头线:=VA3*EMA(操盘线,6); PARTLINE1(空头线>操盘线,操盘线),LINETHICK4,COLORGREEN; PARTLINE1(空头线<操盘线,操盘线),LINETHICK4,COLORRED;

    TY:=C; X:=8; A1:=REF(TY,X)=HHV(TY,2*X+1);  B1:=FILTER(A1,X);  C1E:=BACKSET(B1,X+1);  HD:=FILTER(C1E,X); A2:=REF(TY,X)=LLV(TY,2*X+1);  B2:=FILTER(A2,X);  C2:=BACKSET(B2,X+1);  LD:=FILTER(C2,X); AQ:=REF(C,BARSLAST(HD));  BQ:=REF(C,BARSLAST(LD)); T1:=BARSLAST(HD)<BARSLAST(LD) AND NOT(HD) ; T2:=BARSLAST(HD)>BARSLAST(LD) AND NOT(LD); 上:IF(T1,AQ,AQ),COLORFFF666,LINETHICK2; STICKLINE(T1,AQ,AQ,2,0),COLORFFFFFF; 下:IF(T2,BQ,BQ),COLORFF999F,LINETHICK2; STICKLINE(T2,BQ,BQ,2,0),COLORFFFFFF;


    KS:=(((CLOSE - EMA(CLOSE,8)) / EMA(CLOSE,8)) * (0 - 100)); 趋Q:=EMA(((KS / 5) + EMA(CLOSE,5)),3); AA:= - 100 * (趋Q - CLOSE) / 趋Q; XQ:=(((CLOSE/21) * 20) + CLOSE); Y:=EMA(CLOSE,10); LLQ:=REF(CLOSE,2); C1W:=(CLOSE+LOW+HIGH)/3; C2W:=EMA(C1W,6); C3W:=EMA(C2W,5); C4:=CROSS(C2W,C3W); RSV:=(CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100; K:=SMA(RSV,3,1); D:=SMA(K,3,1); J:=3*K-2*D; RSV24:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100; K24:=SMA(RSV24,3,1); D24:=SMA(K24,3,1); J24:=3*K24-2*D24; 阻:IF(CROSS(J24,J),HIGH,REF(HIGH,BARSLAST(CROSS(J24,J)))),POINTDOT,LINETHICK2,COLORFF0000,PRECIS1;
    HHQ:=HHV(HIGH,1)/5+HHV(HIGH,2)/5+HHV(HIGH,2)/5+HHV(HIGH,5)/5+HHV   (HIGH,8)/5; LL1Q:=LLV(LOW,1)/5+LLV(LOW,2)/5+LLV(LOW,2)/5+LLV(LOW,5)/5+LLV(LOW,8)/5; H1Q:= IFELSE(H<REF(H,2)&&REF(H,1)<REF(H,2),REF(H,2),0); L1Q:= IFELSE(L>REF(L,2)&&REF(L,1)>REF(L,2),REF(L,2),0); H2Q:=VALUEWHEN(H1Q>0,H1Q); L2:=VALUEWHEN(L1Q>0,L1Q); K1:=IFELSE(CLOSE>H2Q,-3,IFELSE(CLOSE<L2,1,0)); K2:=VALUEWHEN(K1<>0,K1); GG:=IFELSE(K2=1,H2Q,L2); GG1:=VALUEWHEN(ISLASTBAR,GG); TMP1:=K2; W1:=K2; W2:=OPEN-CLOSE; HT:=IFELSE(OPEN>CLOSE,OPEN,CLOSE); LT:=IFELSE(OPEN<CLOSE,OPEN,CLOSE); DRAWTEXT(CROSS(TMP1,0),HHQ,'↓',COLOR00FFFF; DRAWTEXT(CROSS(0,TMP1),LL1Q,'↑',COLORYELLOW; OCH:=MAX(OPEN,CLOSE); OCL:=MIN(OPEN,CLOSE);

 

有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友

可联系技术人员 QQ: 262069696  点击在线交流或微信号:cxh99cxh99  进行 有偿收费 编写!

怎么收费,代编流程等详情请点击阅读!

(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)


【字体: 】【打印文章】【查看评论

相关文章

    没有相关内容