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

老师这个文华指标咋不显示 [文华财经]

  • 咨询内容:  Y1:=(MA(CLOSE,2)+MA(CLOSE,3)+MA(CLOSE,4)+MA(CLOSE,5))/4;Y2:=EMA(Y1,5);Y3:=EMA(Y2,3);YY:EMA(Y3,N1),COLORRED;Z1:=(MA(CLOSE,9)+MA(CLOSE,6)+MA(CLOSE,7)+MA(CLOSE,8))/4;Z2:=EMA(Z1,5);Z3:=EMA(Z2,3);ZZ:EMA(Z3,N2),COLORGREEN;VERTLINE( CROSS( YY,ZZ ) , COLORRED);VERTLINE( CROSS( ZZ, YY), COLORGREEN);DRAWTEXT( CROSS( YY,ZZ ), ZZ, '';DRAWTEXT( CROSS( ZZ,YY ),YY , '';DRAWLINE(YY>=ZZ,HIGH,YY>=ZZ,OPEN,COLORRED);DRAWLINE(YY>=ZZ,LOW,YY>=ZZ,CLOSE,COLORRED);DRAWLINE(YY<ZZ,HIGH,YY<ZZ,CLOSE,COLORCYAN);DRAWLINE(YY<ZZ,LOW,YY<ZZ,OPEN,COLORCYAN);DRAWLINE(ABS(YY-ZZ)<0.00001,LOW,ABS(YY-ZZ)<0.00001,OPEN,COLORWHITE);DRAWLINE(ABS(YY-ZZ)<0.00001,HIGH,ABS(YY-ZZ)<0.00001,OPEN,COLORWHITE);STICKLINE((YY-ZZ)>0.00001,OPEN,CLOSE,COLORRED,1);STICKLINE((YY-ZZ)<-0.00001,OPEN,CLOSE,COLORCYAN,1);

     

     来源:程序化99

  • 文华技术人员:

     我们本地测试是可以显示的

     

    1楼源码中的N1、N2您没有定义?可以自行定义一下:

     

    N1:=10;
    N2:=10;
    Y1:=(MA(CLOSE,2)+MA(CLOSE,3)+MA(CLOSE,4)+MA(CLOSE,5))/4;
    Y2:=EMA(Y1,5);
    Y3:=EMA(Y2,3);
    YY:EMA(Y3,N1),COLORRED;
    Z1:=(MA(CLOSE,9)+MA(CLOSE,6)+MA(CLOSE,7)+MA(CLOSE,8))/4;
    Z2:=EMA(Z1,5);
    Z3:=EMA(Z2,3);
    ZZ:EMA(Z3,N2),COLORGREEN;
    VERTLINE( CROSS( YY,ZZ ) , COLORRED);
    VERTLINE( CROSS( ZZ, YY), COLORGREEN);
    DRAWTEXT( CROSS( YY,ZZ ), ZZ, '';
    DRAWTEXT( CROSS( ZZ,YY ),YY , '';
    DRAWLINE(YY>=ZZ,HIGH,YY>=ZZ,OPEN,COLORRED);
    DRAWLINE(YY>=ZZ,LOW,YY>=ZZ,CLOSE,COLORRED);
    DRAWLINE(YY<ZZ,HIGH,YY<ZZ,CLOSE,COLORCYAN);
    DRAWLINE(YY<ZZ,LOW,YY<ZZ,OPEN,COLORCYAN);
    DRAWLINE(ABS(YY-ZZ)<0.00001,LOW,ABS(YY-ZZ)<0.00001,OPEN,COLORWHITE);
    DRAWLINE(ABS(YY-ZZ)<0.00001,HIGH,ABS(YY-ZZ)<0.00001,OPEN,COLORWHITE);
    STICKLINE((YY-ZZ)>0.00001,OPEN,CLOSE,COLORRED,1);
    STICKLINE((YY-ZZ)<-0.00001,OPEN,CLOSE,COLORCYAN,1);

 

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

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


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

相关文章

    没有相关内容