Rss & SiteMap

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

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

标题:[求助]模型编写

1楼
木瓜 发表于:2014/2/20 20:33:58

请教模型编写:

假设

A为多单条件

B为空单条件

请教下面的交易模式表达

 

如果符合A,开多单

如果不符合A,平多单

 

如果符合B开空单

如果不符合B,平空单

 

谢谢!!

2楼
木瓜 发表于:2014/2/20 21:05:00

补充一下:

A为多单条件,只要符合条件A,持有多单

B为空单条件,只要符合条件B,持有空单

3楼
jinzhe 发表于:2014/2/21 9:25:15

if a and holding=0 then buy(1,1,market);

if not(a) and holding>0 then sell(1,0,market);

if b and holding=0 then buyshort(1,1,market);

if not(b) and holding<) then sellshort(1,0,market);

4楼
木瓜 发表于:2014/2/21 22:17:15
谢谢版主~!!!
共4 条记录, 每页显示 10 条, 页签: [1]


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