Rss & SiteMap

金字塔客服中心 - 专业程序化交易软件提供商 http://www.weistock.com/bbs/

专业程序化软件提供商
共2 条记录, 每页显示 10 条, 页签: [1]
[浏览完整版]

标题:程序本来是要多,要么空,要么没有单,可今天出现了一个情况

1楼
大灰狼 发表于:2013/6/24 17:05:52
在逻辑上或语句上有什么问题,程序本来是要多,要么空,要么没有单,可今天出现了一个情况,

//开多
if dblcom then begin                 
        sellshort(holding<0,holding,market),orderqueue;
        buy(holding=0,sv,market);
              end  else begin
              if (long and not(ddblcom)) then begin
                 sellshort(holding<0,0,market),orderqueue;
                 buy(holding=0,sv,market);
                       end
                  end 
//开空                     
if ddblcom then begin                     
                 sell(holding>0,0,market),orderqueue;
                 buyshort(holding=0,sv,market); 
                end else  begin 
                     if (short and  not(dblcom)) then begin
                     sell(holding>0,0,market),orderqueue;
                     buyshort(holding=0,sv,market);
                                  end 
                           end       
//平多
if longX then begin
    sell(holding>0,0,market);
     end
   
  //平空
  if shortX then begin
     sellshort(holding<0,0,market); 
       end  
36  17:03:48
先开了多,随后又平多开空,可是帐户上多单还在。
2楼
jinzhe 发表于:2013/6/25 9:22:18
模拟交易还是实盘交易?有没有记录下单日志?
共2 条记录, 每页显示 10 条, 页签: [1]


Powered By Dvbbs Version 8.3.0
Processed in 0.03125 s, 3 queries.