Rss & SiteMap

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

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

标题:求助语句毛病

1楼
versus11 发表于:2012/12/26 15:36:46
 DY;=h-l
if holding>0 and LONG and (c-ENTERPRICE)>DY then
sell(holding>0,holding/2,MARKET);
if holding>0 and LONG and (c-enterprice)>DY*2 then 
sell(holding>0,0.MARKFT);

语句在执行过程没有体现2倍DY的价格 在执行过程中会一直开多平多。我只想日内开一次仓。
2楼
jinzhe 发表于:2012/12/26 15:49:05

那么就是DY设定的价格不合理,改成其他的

每天开一次仓,就需要用全局变量来限定

 

variable:a=0;

if 条件 and a=0 then begin

buy;

a:=1;

end

 

if time=090100 then

a:=0;

 

 

共2 条记录, 每页显示 10 条, 页签: [1]


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