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

修改成文华指标 [文华财经]

  • 咨询内容:  
    X:=(3*C+L+O+H)/6;{主趋势线:EMA(EMA(C,10),10),COLORBLUE,LINETHICK3;;B:=主趋势线<REF(主趋势线,1);IF(B-1,主趋势线,DRAWNULL)COLORRED,LINETHICK3;}主趋势线:EMA(EMA(C,10),10),COLORRED,LINETHICK3;B:=主趋势线>REF(主趋势线,1);IF(B-1,主趋势线,DRAWNULL)COLORBLUE,LINETHICK3;操盘线:EMA(EMA(C,5),5),COLORRED,LINETHICK2;Y:=操盘线>REF(操盘线,1);IF(Y-1,操盘线,DRAWNULL)COLORGREEN,LINETHICK2;
    AA:=EMA(C,5) > EMA(C,20);BB:=EMA(C,5) < EMA(C,20);CC:= EMA(C,5) > EMA(C,10);CC1:=EMA(C,5) < EMA(C,10);DD:=CLOSE<OPEN;

    STICKLINE(AA,H,L,0,0),COLORRED;STICKLINE(AA,O,C,3,1),COLORRED;STICKLINE(AA AND DD,O,C,3,0),COLORRED;STICKLINE(BB,H,L,0,0),COLORGREEN;STICKLINE(BB,O,C,3,1),COLORGREEN;
    STICKLINE(BB AND DD,O,C,3,0),COLORGREEN;STICKLINE(BB AND CC,H,L,0,1),COLORWHITE;STICKLINE(BB AND CC,O,C,3,1),COLORWHITE;STICKLINE(BB AND CC AND DD,O,C,3,0),COLORWHITE;STICKLINE(AA AND CC1,H,L,0,0),COLORWHITE;STICKLINE(AA AND CC1,O,C,3,1),COLORWHITE;STICKLINE(AA AND CC1 AND DD,O,C,3,0),COLORWHITE;




    VAR3:=LLV(HIGH,240);VAR4:=100*(CLOSE-VAR3)/VAR3;VAR5:=(CLOSE-LLV(LOW,528))/(HHV(HIGH,528)-LLV(LOW,528))*100;VAR6:=(CLOSE-LLV(CLOSE,530))/(HHV(CLOSE,530)-LLV(CLOSE,530))*100;VAR7:=0;VAR8:=SMA(MAX(CLOSE-REF(CLOSE,1),0),34,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100;VAR9:=SMA(MAX(CLOSE-REF(CLOSE,1),0),13,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),13,1)*100;VAR10:=IF(TROUGHBARS(3,16,1)=0 AND HIGH>LOW+0.04,4,0);VAR11:=ZIG(3,6)>REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)<=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)<=REF(ZIG(3,6),3);VAR12:=ZIG(3,6)<REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)>=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)>=REF(ZIG(3,6),3);VAR13:=ZIG(3,22)>REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)<=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)<=REF(ZIG(3,22),3);VAR14:=ZIG(3,22)<REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)>=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)>=REF(ZIG(3,22),3);VAR15:=ZIG(3,51)>REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)<=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)<=REF(ZIG(3,51),3);VAR16:=ZIG(3,51)<REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)>=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)>=REF(ZIG(3,51),3);VAR17:=ZIG(3,72)>REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)<=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)<=REF(ZIG(3,72),3);VAR18:=ZIG(3,72)<REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)>=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)>=REF(ZIG(3,72),3);VAR19:=EMA(CLOSE,2)-EMA(CLOSE,150);Z1:=STRCAT(HYBLOCK,' ');Z2:=STRCAT(Z1,DYBLOCK);Z3:=STRCAT(Z2,' ');DRAWTEXT_FIX(ISLASTBAR,0,0,0,STRCAT(Z3,GNBLOCK));TY:=C;A1:=REF(TY,10)=HHV(TY,2*10+1); B1:=FILTER(A1,10); C1:=BACKSET(B1,10+1); HD:=FILTER(C1,10);A2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(A2,10); C2:=BACKSET(B2,10+1); LD:=FILTER(C2,10);前期高位:REF(C,BARSLAST(HD)),COLOR00FF00,POINTDOT;STICKLINE(C,前期高位,前期高位,8,0),COLORYELLOW;VAR444:=C;操作:=MA(VAR444,5);生命线:HHV(操作,13),LINETHICK2,COLORYELLOW;A0:=(L+H+C*2)/4;

     

  • 文华技术人员:  查看了一下你的源码,其中含有未来函数ZIG ,赢顺版本中是不支持之字转向函数的。赢智版本是可以支持的,你可以将源码加载到赢智8.2版本中使用.下载地址:www.wenhua.com.cn 

    X:=(3*C+L+O+H)/6;主趋势线:EMA(EMA(C,10),10),COLORRED,LINETHICK3;B:=主趋势线>REF(主趋势线,1);IF(B-1,主趋势线,NULL),COLORBLUE,LINETHICK3;操盘线:EMA(EMA(C,5),5),COLORRED,LINETHICK2;Y:=操盘线>REF(操盘线,1);IF(Y-1,操盘线,NULL),COLORGREEN,LINETHICK2;AA:=EMA(C,5) > EMA(C,20);BB:=EMA(C,5) < EMA(C,20);CC:= EMA(C,5) > EMA(C,10);CC1:=EMA(C,5) < EMA(C,10);DD:=CLOSE<OPEN;STICKLINE1(AA,H,L,0,0),COLORRED;STICKLINE1(AA,O,C,3,1),COLORRED;STICKLINE1(AA AND DD,O,C,3,0),COLORRED;STICKLINE1(BB,H,L,0,0),COLORGREEN;STICKLINE1(BB,O,C,3,1),COLORGREEN;STICKLINE1(BB AND DD,O,C,3,0),COLORGREEN;STICKLINE1(BB AND CC,H,L,0,1),COLORWHITE;STICKLINE1(BB AND CC,O,C,3,1),COLORWHITE;STICKLINE1(BB AND CC AND DD,O,C,3,0),COLORWHITE;STICKLINE1(AA AND CC1,H,L,0,0),COLORWHITE;STICKLINE1(AA AND CC1,O,C,3,1),COLORWHITE;STICKLINE1(AA AND CC1 AND DD,O,C,3,0),COLORWHITE;VAR3:=LLV(HIGH,240);VAR4:=100*(CLOSE-VAR3)/VAR3;VAR5:=(CLOSE-LLV(LOW,528))/(HHV(HIGH,528)-LLV(LOW,528))*100;VAR6:=(CLOSE-LLV(CLOSE,530))/(HHV(CLOSE,530)-LLV(CLOSE,530))*100;VAR7:=0;VAR8:=SMA(MAX(CLOSE-REF(CLOSE,1),0),34,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100;VAR9:=SMA(MAX(CLOSE-REF(CLOSE,1),0),13,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),13,1)*100;VAR10:=IF(TROUGHBARS(C,16,1,1)=0 AND HIGH>LOW+0.04,4,0);VAR11:=ZIGZAG(C,6,1)>REF(ZIGZAG(C,6,1),1) AND REF(ZIGZAG(C,6,1),1)<=REF(ZIGZAG(C,6,1),2) AND REF(ZIGZAG(C,6,1),2)<=REF(ZIGZAG(C,6,1),3);VAR12:=ZIGZAG(C,6,1)<REF(ZIGZAG(C,6,1),1) AND REF(ZIGZAG(C,6,1),1)>=REF(ZIGZAG(C,6,1),2) AND REF(ZIGZAG(C,6,1),2)>=REF(ZIGZAG(C,6,1),3);VAR13:=ZIGZAG(C,22,1)>REF(ZIGZAG(C,22,1),1) AND REF(ZIGZAG(C,22,1),1)<=REF(ZIGZAG(C,22,1),2) AND REF(ZIGZAG(C,22,1),2)<=REF(ZIGZAG(C,22,1),3);VAR14:=ZIGZAG(C,22,1)<REF(ZIGZAG(C,22,1),1) AND REF(ZIGZAG(C,22,1),1)>=REF(ZIGZAG(C,22,1),2) AND REF(ZIGZAG(C,22,1),2)>=REF(ZIGZAG(C,22,1),3);VAR15:=ZIGZAG(C,51,1)>REF(ZIGZAG(C,51,1),1) AND REF(ZIGZAG(C,51,1),1)<=REF(ZIGZAG(C,51,1),2) AND REF(ZIGZAG(C,51,1),2)<=REF(ZIGZAG(C,51,1),3);VAR16:=ZIGZAG(C,51,1)<REF(ZIGZAG(C,51,1),1) AND REF(ZIGZAG(C,51,1),1)>=REF(ZIGZAG(C,51,1),2) AND REF(ZIGZAG(C,51,1),2)>=REF(ZIGZAG(C,51,1),3);VAR17:=ZIGZAG(C,72,1)>REF(ZIGZAG(C,72,1),1) AND REF(ZIGZAG(C,72,1),1)<=REF(ZIGZAG(C,72,1),2) AND REF(ZIGZAG(C,72,1),2)<=REF(ZIGZAG(C,72,1),3);VAR18:=ZIGZAG(C,72,1)<REF(ZIGZAG(C,72,1),1) AND REF(ZIGZAG(C,72,1),1)>=REF(ZIGZAG(C,72,1),2) AND REF(ZIGZAG(C,72,1),2)>=REF(ZIGZAG(C,72,1),3);VAR19:=EMA(CLOSE,2)-EMA(CLOSE,150);TY:=C;A1:=REF(TY,10)=HHV(TY,2*10+1); B1:=FILTER(A1,10); C1:=BACKSET(B1,10+1); HD:=FILTER(C1,10);A2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(A2,10); C2:=BACKSET(B2,10+1); LD:=FILTER(C2,10);前期高位:REF(C,BARSLAST(HD)),COLOR00FF00,POINTDOT;STICKLINE1(C,前期高位,前期高位,8,0),COLORYELLOW;VAR444:=C;操作:=MA(VAR444,5);生命线:HHV(操作,13),LINETHICK2,COLORYELLOW;A0:=(L+H+C*2)/4; 

     

  • 文华客服:  

     

  • 网友回复:  

     

  • 网友回复:   查看了一下你的源码,其中含有未来函数ZIG ,赢顺版本中是不支持之字转向函数的。赢智版本是可以支持的,你可以将源码加载到赢智8.2版本中使用. 下载地址:www.wenhua.com.cn 

 

有思路,想编写各种指标公式,程序化交易模型,选股公式,预警公式的朋友

可联系技术人员 QQ: 511411198  点击这里给我发消息进行 有偿 编写!不贵!点击查看价格!


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

相关文章

    没有相关内容