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


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

   

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


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

主题:有信号,不交易

帅哥哟,离线,有人找我吗?
Mikewang
  21楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:122 积分:0 威望:0 精华:0 注册:2015/12/9 12:32:38
  发帖心情 Post By:2016/3/17 14:40:25    Post IP:101.90.254.247[只看该作者]

程序的命令是开仓按走完K线,平仓实时执行的。怎么实现这个目的?

 回到顶部
帅哥哟,离线,有人找我吗?
Mikewang
  22楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:122 积分:0 威望:0 精华:0 注册:2015/12/9 12:32:38
  发帖心情 Post By:2016/3/17 14:43:34    Post IP:101.90.254.247[只看该作者]

另外,还有我对持仓人工干预全部平仓,然而软件仍然显示持有仓位,怎么也平仓不掉。怎么办?


 回到顶部
帅哥哟,离线,有人找我吗?
jinzhe
  23楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:罗宾汉 帖子:46311 积分:50819 威望:0 精华:2 注册:2011/3/23 8:50:25
  发帖心情 Post By:2016/3/17 14:45:50    Post IP:58.246.57.26[只看该作者]

1.实现不了在走完k线的模式下执行即时平仓

2.图表交易的信号,由此产生的虚拟持仓,是要由图表上的平仓才能去掉,手工是平不掉虚拟持仓的



金字塔—专业程序化交易量化投资平台

客户服务部

----------------------------------------------------------- 欢迎您参加我公司的技术培训,具体培训需求请发邮件到service@weistock.com

您的宝贵建议或者投诉,请发往邮箱:weiwei@weistock.com

 回到顶部
帅哥哟,离线,有人找我吗?
Mikewang
  24楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:122 积分:0 威望:0 精华:0 注册:2015/12/9 12:32:38
  发帖心情 Post By:2016/3/17 14:53:30    Post IP:101.90.254.247[只看该作者]

哦   那么:
1、程序的命令是开仓按走完K线,平仓实时执行的。怎么来实现这个目的呢?
2、会不会在实盘时也出现虚拟持仓。(我曾经实盘了一次,与模拟盘是完全一样的。)

 回到顶部
帅哥哟,离线,有人找我吗?
jinzhe
  25楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:罗宾汉 帖子:46311 积分:50819 威望:0 精华:2 注册:2011/3/23 8:50:25
  发帖心情 Post By:2016/3/17 15:11:21    Post IP:58.246.57.26[只看该作者]

buy(CROSS(H1,H2) and holding=0,1,thisclose);
buyshort(CROSS(H2,H1) and holding=0,1,thisclose);
 
改成
buy(ref(CROSS(H1,H2),1) and holding=0,1,thisclose);
buyshort(ref(CROSS(H2,H1),1) and holding=0,1,thisclose);
其他不变,使用固定时间间隔模式
 
 


金字塔—专业程序化交易量化投资平台

客户服务部

----------------------------------------------------------- 欢迎您参加我公司的技术培训,具体培训需求请发邮件到service@weistock.com

您的宝贵建议或者投诉,请发往邮箱:weiwei@weistock.com

 回到顶部
帅哥哟,离线,有人找我吗?
jinzhe
  26楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:罗宾汉 帖子:46311 积分:50819 威望:0 精华:2 注册:2011/3/23 8:50:25
  发帖心情 Post By:2016/3/17 15:12:00    Post IP:58.246.57.26[只看该作者]

以下是引用Mikewang在2016/3/17 14:53:30的发言:
哦   那么:
1、程序的命令是开仓按走完K线,平仓实时执行的。怎么来实现这个目的呢?
2、会不会在实盘时也出现虚拟持仓。(我曾经实盘了一次,与模拟盘是完全一样的。)

虚拟持仓和实盘还是模拟交易没关系。只要是图表交易,持仓都是虚拟持仓,不和实际账户持仓相关



金字塔—专业程序化交易量化投资平台

客户服务部

----------------------------------------------------------- 欢迎您参加我公司的技术培训,具体培训需求请发邮件到service@weistock.com

您的宝贵建议或者投诉,请发往邮箱:weiwei@weistock.com

 回到顶部
客人(101.90.*.*)
  27楼


  发帖心情 Post By:2016/3/17 16:24:37    Post IP:101.90.254.247[只看该作者]

1、对应25楼的,其中程序有关的SELL与sellshort是否也要改变呢?
2、使用固定时间间隔模式会不会重复开仓呢?


 回到顶部
帅哥哟,离线,有人找我吗?
Mikewang
  28楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:122 积分:0 威望:0 精华:0 注册:2015/12/9 12:32:38
  发帖心情 Post By:2016/3/17 16:35:46    Post IP:101.90.254.247[只看该作者]

刚才代入后,显示开仓(包括开多仓与开空仓)都推迟到了下一个K线了

 回到顶部
帅哥哟,离线,有人找我吗?
jinzhe
  29楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:罗宾汉 帖子:46311 积分:50819 威望:0 精华:2 注册:2011/3/23 8:50:25
  发帖心情 Post By:2016/3/17 16:36:28    Post IP:58.246.57.26[只看该作者]

1.25楼讲过了“其他不变”

2.不会重复开仓,以固定时间间隔的模式来实现走完k线下单



金字塔—专业程序化交易量化投资平台

客户服务部

----------------------------------------------------------- 欢迎您参加我公司的技术培训,具体培训需求请发邮件到service@weistock.com

您的宝贵建议或者投诉,请发往邮箱:weiwei@weistock.com

 回到顶部
帅哥哟,离线,有人找我吗?
Mikewang
  30楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:论坛游民 帖子:122 积分:0 威望:0 精华:0 注册:2015/12/9 12:32:38
  发帖心情 Post By:2016/3/17 16:47:19    Post IP:101.90.254.247[只看该作者]

好的,已经明白。但是 ,这样开多仓与开空仓)都推迟到了下一个K线了。我在开平仓后也加入了orderqueue。目前程序是:
sellshort(CROSS(H1,H2),0,marketr) orderqueue;

buy(ref(CROSS(H1,H2),1) and holding=0,1,thisclose) orderqueue;

sell(CROSS(H2,H1) ,0,marketr) orderqueue;

buyshort(ref(CROSS(H2,H1),1) and holding=0,1,thisclose) orderqueue;

多止损:sell(rounds(C,3)<rounds(ENTERPRICE,3)-15*MINDIFF,holding,marketr) orderqueue;

空止损:sellshort(rounds(C,3)>rounds(ENTERPRICE,3)+15*MINDIFF,holding,marketr) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+3*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+4*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+1*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+1*mindiff) and enterbars>0 then 多止盈1:sell(1,0, limitr,enterprice+1*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+5*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+6*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+3*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+3*mindiff) and enterbars>0 then 多止盈2:sell(1,0, limitr,enterprice+3*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+7*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+8*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+5*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+5*mindiff) and enterbars>0 then 多止盈3:sell(1,0, limitr,enterprice+5*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+9*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+10*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+7*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+7*mindiff) and enterbars>0 then 多止盈4:sell(1,0, limitr,enterprice+7*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+11*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+12*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+9*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+9*mindiff) and enterbars>0 then 多止盈5:sell(1,0, limitr,enterprice+9*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+13*mindiff and rounds(hhv(h,enterbars+1),3)<=rounds(enterprice,3)+14*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)+11*mindiff) and (rounds(l,3)<=rounds(enterprice,3)+11*mindiff) and enterbars>0 then 多止盈6:sell(1,0, limitr,enterprice+11*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-3*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-4*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-1*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-1*mindiff) and enterbars>0 then 空止盈1:sellshort(1,0, limitr,enterprice-1*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-5*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-6*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-3*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-3*mindiff) and enterbars>0 then 空止盈2:sellshort(1,0, limitr,enterprice-3*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-7*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-8*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-5*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-5*mindiff) and enterbars>0 then 空止盈3:sellshort(1,0, limitr,enterprice-5*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-9*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-10*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-7*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-7*mindiff) and enterbars>0 then 空止盈4:sellshort(1,0, limitr,enterprice-7*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-11*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-12*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-9*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-9*mindiff) and enterbars>0  then 空止盈5:sellshort(1,0, limitr,enterprice-9*mindiff) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-13*mindiff and rounds(llv(l,enterbars+1),3)>=rounds(enterprice,3)-14*mindiff  and  (rounds(h,3)>=rounds(enterprice,3)-11*mindiff) and (rounds(l,3)<=rounds(enterprice,3)-11*mindiff) and enterbars>0 then 空止盈6:sellshort(1,0, limitr,enterprice-11*mindiff) orderqueue;

if rounds(hhv(h,enterbars+1),3)>=rounds(enterprice,3)+15*mindiff and rounds(close,3)<=rounds(hhv(h,enterbars+1),3)-3*mindiff and enterbars>0 then 移动平多:sell(1,0,market) orderqueue;

if rounds(llv(l,enterbars+1),3)<=rounds(enterprice,3)-15*mindiff and rounds(close,3)>=rounds(llv(l,enterbars+1),3)+3*mindiff and enterbars>0 then 移动平空:sellshort(1,0,market) orderqueue;

if openprofit>=0 and time0>=(timetot0(closetime(0))- 2*60) then begin

收盘平多:sell(1,0,market) orderqueue;

收盘平空:sellshort(1,0,market) orderqueue;

time0<=timetot0(closetime(0))-2*60;

end;


 回到顶部
总数 44 上一页 1 2 3 4 5 下一页