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

老师请帮我改写 [文华财经]

  • 咨询内容:

     DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);
    DEA:=EMA(DIFF,9);
    DRAWICON(DIFF>DEA,1,4);
    DRAWICON(DIFF<DEA,1,5);
    DRAWTEXT(ISLASTBAR=1,1,'MACD',COLORFFFFFF;
    A1:=DIFF>DEA;
    RSV1:=(CLOSE-LLV(LOW,45))/(HHV(HIGH,45)-LLV(LOW,45))*100;
    K:=SMA(RSV1,9,1);
    D:=SMA(K,3,1);
    DRAWICON(K>D,2,4);
    DRAWICON(K<D,2,5);
    DRAWTEXT(ISLASTBAR=1,2,'KDJ',COLORFFFFFF;
    A2:=K>D;
    LC:=REF(CLOSE,1);
    RSI1:=(SMA(MAX(CLOSE-LC,0),10,1))/(SMA(ABS(CLOSE-LC),21,1))*100;
    RSI2:=(SMA(MAX(CLOSE-LC,0),18,1))/(SMA(ABS(CLOSE-LC),36,1))*100;
    DRAWICON(RSI1>RSI2,3,4);
    DRAWICON(RSI1<RSI2,3,5);
    DRAWTEXT(ISLASTBAR=1,3,'RSI',COLORFFFFFF;
    A3:=RSI1>RSI2;
    RSV:=-(HHV(HIGH,14)-CLOSE)/(HHV(HIGH,14)-LLV(LOW,14))*100;
    LWR1:=SMA(RSV,14,1);
    LWR2:=SMA(LWR1,14,1);
    DRAWICON(LWR1>LWR2,4,4);
    DRAWICON(LWR1<LWR2,4,5);
    DRAWTEXT(ISLASTBAR=1,4,'LW&R',COLORFFFFFF;
    A4:=LWR1>LWR2;
    BBI:=(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4;
    DRAWICON(CLOSE>BBI,5,4);
    DRAWICON(CLOSE<BBI,5,5);
    DRAWTEXT(ISLASTBAR=1,5,'BBI',COLORFFFFFF;
    A5:=CLOSE>BBI;

     

    把RSI部分去掉,改换写成BOLL,当K线站上在布林线中轨时,显示红色箭头,当K线跌破布林线中轨在其下方时,显示绿色箭头

     

     来源:程序化99

  • 文华技术人员:  参考:
     MID:MA(CLOSE,12),DOT; TMP2:=STD(CLOSE,26); TOP:MID+2*TMP2,DOT; BOTTOM:MID-2*TMP2,DOT; DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIFF,9); DRAWICON(DIFF>DEA,1,4); DRAWICON(DIFF<DEA,1,5); DRAWTEXT(ISLASTBAR=1,1,'MACD',COLORFFFFFF; A1:=DIFF>DEA; RSV1:=(CLOSE-LLV(LOW,45))/(HHV(HIGH,45)-LLV(LOW,45))*100; K:=SMA(RSV1,9,1); D:=SMA(K,3,1); DRAWICON(K>D,2,4); DRAWICON(K<D,2,5); DRAWTEXT(ISLASTBAR=1,2,'KDJ',COLORFFFFFF; A2:=K>D;

    RSV:=-(HHV(HIGH,14)-CLOSE)/(HHV(HIGH,14)-LLV(LOW,14))*100; LWR1:=SMA(RSV,14,1); LWR2:=SMA(LWR1,14,1); DRAWICON(LWR1>LWR2,4,4); DRAWICON(LWR1<LWR2,4,5); DRAWTEXT(ISLASTBAR=1,4,'LW&R',COLORFFFFFF; A4:=LWR1>LWR2; BBI:=(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4; DRAWICON(CLOSE>BBI,5,4); DRAWICON(CLOSE<BBI,5,5); DRAWTEXT(ISLASTBAR=1,5,'BBI',COLORFFFFFF; A5:=CLOSE>BBI; DRAWICON(C>MID,MID,4); DRAWICON(C<MID,MID,5);

     

     来源: WWW.CXH99.COM

  • 文华客服:

     




    文件名:错错错.jpg

     

     



    文件名:aaa.jpg

     

     

    老师,效果不对啊,把图中RSI  那一行换成BOLL,当K线站上在布林线中轨时,显示向上红色箭头,当K线跌破布林线中轨在其下方时,显示向下绿色箭头



     

     

  • 网友回复: 这么看下:
    MID:=MA(CLOSE,12),DOT; TMP2:=STD(CLOSE,26); TOP:=MID+2*TMP2,DOT; BOTTOM:=MID-2*TMP2,DOT; DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26); DEA:=EMA(DIFF,9); DRAWICON(DIFF>DEA,1,4); DRAWICON(DIFF<DEA,1,5); DRAWTEXT(ISLASTBAR=1,1,'.MACD'),COLORFFFFFF; A1:=DIFF>DEA; RSV1:=(CLOSE-LLV(LOW,45))/(HHV(HIGH,45)-LLV(LOW,45))*100; K:=SMA(RSV1,9,1); D:=SMA(K,3,1); DRAWICON(K>D,2,4); DRAWICON(K<D,2,5); DRAWTEXT(ISLASTBAR=1,2,'.KDJ'),COLORFFFFFF; A2:=K>D;

    RSV:=-(HHV(HIGH,14)-CLOSE)/(HHV(HIGH,14)-LLV(LOW,14))*100; LWR1:=SMA(RSV,14,1); LWR2:=SMA(LWR1,14,1); DRAWICON(LWR1>LWR2,4,4); DRAWICON(LWR1<LWR2,4,5); DRAWTEXT(ISLASTBAR=1,4,'.LW&R'),COLORFFFFFF; A4:=LWR1>LWR2; BBI:=(MA(CLOSE,3)+MA(CLOSE,6)+MA(CLOSE,12)+MA(CLOSE,24))/4; DRAWICON(CLOSE>BBI,5,4); DRAWICON(CLOSE<BBI,5,5); DRAWTEXT(ISLASTBAR=1,5,'.BBI'),COLORFFFFFF; A5:=CLOSE>BBI; DRAWICON(C>MID,3,4); DRAWICON(C<MID,3,5);

 

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

可联系技术人员 QQ: 1145508240  点击在线交流或微信号:cxh99cxh99  进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,谢谢您!)

怎么收费,代编流程等详情请点击阅读,或QQ微信联系我们!


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

相关文章

    没有相关内容