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

连亏次数 [金字塔]

  • 咨询内容: 老师好,如果 求的连亏次数的次数,,就是连亏5次,,一共出现了几次,连亏3次,一共出现 几次,测试报告里没有呀

     

  • 金字塔客服:

    没有这样的数据的

     

  • 用户回复: 是软件里没有函数,还是写不出来 ,,,在3年内,,连续亏损3次,4次,5次,,,一共出现了几次,

     

  • 网友回复:

    没有这样的函数的,

    写法参考:

     

    variable:n=0;

    variable:ss3=0,ss4=0,ss5=0;

     

    if 平多条件 and holding>0 then begin

        sell.......;

        if numprofit(1)>=0 then n:=0;

        if numprofit(1)<0 then n:=n+1; 

        if n=3  then ss3:=ss3+1;

        if n=4 then ss4:=ss4+1;

        if n=5 then ss5:=ss5+1

    end

     

    if 平空条件 and holding<0 then begin

        seshortll.......;

        if numprofit(1)>=0 then n:=0;

        if numprofit(1)<0 then n:=n+1; 

           if n=3  then ss3:=ss3+1;

        if n=4 then ss4:=ss4+1;

        if n=5 then ss5:=ss5+1

    end

 

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

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


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

相关文章

    没有相关内容