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


金字塔客服中心 - 专业程序化交易软件提供商金字塔软件公式模型编写问题提交 → 请老师 帮忙 指导。。。谢谢

   

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


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

主题:请老师 帮忙 指导。。。谢谢

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


加好友 发短信
等级:论坛游民 帖子:172 积分:0 威望:0 精华:0 注册:2014/1/3 14:22:36
  发帖心情 Post By:2015/2/27 13:13:37    Post IP:14.123.0.121[只看该作者]

用户已被锁定

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


加好友 发短信
等级:论坛游民 帖子:172 积分:0 威望:0 精华:0 注册:2014/1/3 14:22:36
  发帖心情 Post By:2015/2/27 13:20:37    Post IP:14.123.0.121[只看该作者]

用户已被锁定

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


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

if d1 or d2 or d3 or d4 or d5 then begin

sellshort(1,0,marketr);

buy(holding=0,1,marketr);

end


if k1 or k2 or k3 or k4 or k5 then begin

sell(1,0,marketr);

buyshort(holding=0,1,marketr);

end

 

 

你这个为什么要写两遍?



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

客户服务部

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

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

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


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

variable:n=0; 

if holding>0 and close<ref(low,enterbars) then sell(1,0,thisclose);

if holding<0 and close>ref(h,enterbars) then sellshort(1,0,thisclose);

if pd1 or pd2 or pd3 or pd4 then sell(1,0,thisclose);

if pk1 or pk2 or pk3 or pk4 then sellshort(1,0,thisclose);

if d1 or d2 or d3 or d4 or d5 and holding=0 and n=0 then beign

    buy(1,1,thisclose);

    n:=1;

end

 

if k1 or k2 or k3 or k4 or k5 and holding=0 and n=0 then begin

    buyshort(1,1,thisclose);

    n:=1;

end

if d1 or d2 or d3 or d4 or d5 and n=1 then begin

sellshort(1,0,thisclose);

buy(holding=0 and exitbars>0,1,thisclose);

end

 

if k1 or k2 or k3 or k4 or k5 and n=1 then begin

sell(1,0,thisclose);

buyshort(holding=0 and exitbars>0,1,thisclose);

end



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

客户服务部

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

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

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


加好友 发短信
等级:论坛游民 帖子:172 积分:0 威望:0 精华:0 注册:2014/1/3 14:22:36
  发帖心情 Post By:2015/2/27 13:46:35    Post IP:14.123.0.121[只看该作者]

用户已被锁定

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


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

不是,只写一遍

我前面写的,也是只有一遍



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

客户服务部

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

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

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


加好友 发短信
等级:论坛游民 帖子:172 积分:0 威望:0 精华:0 注册:2014/1/3 14:22:36
  发帖心情 Post By:2015/2/27 14:02:59    Post IP:14.123.0.121[只看该作者]

用户已被锁定

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


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

variable:n=0; 

if holding>0 and close<ref(low,enterbars) then sell(1,0,thisclose);

if holding<0 and close>ref(h,enterbars) then sellshort(1,0,thisclose);

if pd1 or pd2 or pd3 or pd4 then sell(1,0,thisclose);

if pk1 or pk2 or pk3 or pk4 then sellshort(1,0,thisclose);

if (d1 or d2 or d3 or d4 or d5) and holding=0 and n=0 then beign

    buy(1,1,thisclose);

    n:=1;

end


if (k1 or k2 or k3 or k4 or k5) and holding=0 and n=0 then begin

    buyshort(1,1,thisclose);

    n:=1;

end

if (d1 or d2 or d3 or d4 or d5) and n=1 then begin

sellshort(1,0,thisclose);

buy(holding=0 and exitbars>0,1,thisclose);

end


if (k1 or k2 or k3 or k4 or k5) and n=1 then begin

sell(1,0,thisclose);

buyshort(holding=0 and exitbars>0,1,thisclose);

end

 

逻辑判断上出了问题,我加了几对括号,你再看看结果



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

客户服务部

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

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

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


加好友 发短信
等级:论坛游民 帖子:172 积分:0 威望:0 精华:0 注册:2014/1/3 14:22:36
  发帖心情 Post By:2015/2/27 15:27:36    Post IP:14.123.0.121[只看该作者]

用户已被锁定

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


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

那是对的,你的要求是止损后再出现开仓条件才开仓,而不是止损后马上反手



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

客户服务部

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

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

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