欢迎使用金字塔普通技术服务论坛,您可以在相关区域发表技术支持贴。
我司技术服务人员将优先处理 VIP客服论坛 服务贴,普通区问题处理速度慢,请耐心等待。谢谢您对我们的支持与理解。


金字塔客服中心 - 专业程序化交易软件提供商金字塔软件公式模型编写问题提交 → 信号异常问题

   

欢迎使用金字塔普通技术服务论坛,您可以在相关区域发表技术支持贴。
我司技术服务人员将优先处理 VIP客服论坛 服务贴,普通区问题处理速度慢,请耐心等待。谢谢您对我们的支持与理解。    


  共有3128人关注过本帖树形打印复制链接

主题:信号异常问题

帅哥哟,离线,有人找我吗?
qq代人发帖
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:超级版主 帖子:18691 积分:0 威望:0 精华:0 注册:2013/7/15 9:22:16
信号异常问题  发帖心情 Post By:2017/6/5 15:27:26    Post IP:180.169.30.6[显示全部帖子]

 //后台持仓同步系统
cc:=holding;
if tholding>0 and kkcond then sell(1,ss,market);
if tholding<0 and kdcond then sellshort(1,ss,market);
if tholding=0 and buycond then buy(1,ss,market);
if tholding=0 and sellcond then buyshort(1,ss,market);
tm:=20;//撤单时间
wt:=tremainqty(0,'',stklabel);
buyhold:=tbuyholdingex('',stklabel,1);
sellhold:=tsellholdingex('',stklabel,1);
if wt>0.5 and tsubmit(0)>tm then tcancelex(1,0,'',stklabel);
if wt<0.5 then begin
 kc1:=max(cc,0)-buyhold;
 kc2:=abs(min(cc,0))-sellhold;
 if kc1<-0.5 then tsell(1,abs(kc1),mkt,0,0,''),allowrepeat;
 if kc2<-0.5 then tsellshort(1,abs(kc2),mkt,0,0,''),allowrepeat;
 if sellhold<0.5 and kc1>0.5 then tbuy(1,kc1,mkt,0,0,''),allowrepeat;
 if buyhold<0.5  and kc2>0.5 then tbuyshort(1,kc2,mkt,0,0,''),allowrepeat;
end
 

图片点击可在新窗口打开查看此主题相关图片如下:1.png
图片点击可在新窗口打开查看

图片点击可在新窗口打开查看此主题相关图片如下:2.png
图片点击可在新窗口打开查看
出现的是这样???

 回到顶部