您现在的位置:程序化交易>> 期货公式>> 金字塔等>> 金字塔知识>>正文内容

[原创] [金字塔]

  • 咨询内容: 老师帮看一下、这代码是不是哪里写错了,开仓能执行、平仓达到条件了也没平仓思路是这样的:1、最新价比开盘价高5个点、开多,赚5个点平仓、亏8个点平仓、反之;这是后台的

    if  DYNAINFO2(7, PZ1)<=enterprice-8*MINDIFF then begin//多损tsell(1,1,MKT,0); end;if  DYNAINFO2(7, PZ1)>=enterprice+5*MINDIFF then begin//多盈tsell(1,1,MKT,DYNAINFO2(7, PZ1),0);end


    if DYNAINFO2(7, PZ1)>=enterprice+8*MINDIFF then begin//空损tsellshort(1,1,MKT,DYNAINFO2(7, PZ1),0);endif DYNAINFO2(7, PZ1)<=enterprice-5*MINDIFF then begin //空盈tsellshort(1,1,MKT,DYNAINFO2(7, PZ1),0);endif DYNAINFO2(7, PZ1)<=o-4*mindiff and tbuyholdingex(ZH,pz1,0)=0 and tsellholdingex('',pz1,0)=0 then begin//开空tbuyshort(1,1,MKT,DYNAINFO2(7, PZ1),0);end
    if DYNAINFO2(7, PZ1)>=o+4*mindiff AND tbuyholdingex('',pz1,0)=0 and tsellholdingex('',pz1,0)=0 then begin //开多tbuy(1,1,MKT,DYNAINFO2(7, PZ1),0);end

     

  • 金字塔客服: 后台是用tenterprice,不是enterprice

     

  • 用户回复: 谢谢、我再试试

 

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

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


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

相关文章

    没有相关内容