以文本方式查看主题 - 金字塔客服中心 - 专业程序化交易软件提供商 (http://weistock.com/bbs/index.asp) -- 公式模型编写问题提交 (http://weistock.com/bbs/list.asp?boardid=4) ---- [原创] (http://weistock.com/bbs/dispbbs.asp?boardid=4&id=98655) |
-- 作者:我不是新手 -- 发布时间:2016/6/17 10:25:33 -- [原创] 用2分钟的周期、当某根K线的波动大于10个点时开仓,比如:1、某根K线的最新价大于开盘价10个跳、开多,设置10个点的止损、盈利3个点止盈。 2、某根K线的最新价小于开盘价10个跳、开空,设置10个点的止损、盈利3个点止盈。 谢谢
|
-- 作者:jinzhe -- 发布时间:2016/6/17 10:32:46 -- 1、某根K线的最新价大于开盘价10个跳、开多,设置10个点的止损、盈利3个点止盈。 2、某根K线的最新价小于开盘价10个跳、开空,设置10个点的止损、盈利3个点止盈。
if c>o+10*mindiff then buy(holding=0,1,marketr);
if holding>0 and c<enterprice-10 then sell(1,0,marketr);
if holding>0 and c>enterprice+3 then sell(1,0,marketr);
if c<o-10*mindiff then buyshort(holding=0,1,marketr);
if holding<0 and c>enterprice+10 then sellshort(1,0,marketr);
if holding<0 and c<enterprice-3 then sellshort(1,0,marketr); |
-- 作者:我不是新手 -- 发布时间:2016/6/17 14:18:06 -- 把收盘价改成最新价DYNAINFO(7),这样可以吗? if DYNAINFO(7)>o+10*mindiff then buy(holding=0,1,MARKET); if holding>0 and DYNAINFO(7)<enterprice-10 then sell(1,0,MARKET); if holding>0 and DYNAINFO(7)>enterprice+3 then sell(1,0,MARKET); if DYNAINFO(7)<o-10*mindiff then buyshort(holding=0,1,MARKET); if holding<0 and DYNAINFO(7)>enterprice+10 then sellshort(1,0,MARKET); if holding<0 and DYNAINFO(7)<enterprice-3 then sellshort(1,0,MARKET); |
-- 作者:jinzhe -- 发布时间:2016/6/17 14:21:44 -- 不行,动态行情函数不能用在图表交易上 |
-- 作者:我不是新手 -- 发布时间:2016/6/17 14:24:31 -- 那这样表的只能用收盘价来写吗?是否还有其他表达方式? 还是要把他改成后台的?改后台的又应该怎么改呢?
|
-- 作者:jinzhe -- 发布时间:2016/6/17 14:25:58 -- close就是表示最新价, |
-- 作者:我不是新手 -- 发布时间:2016/6/17 14:26:57 -- 那这样测评的话得到的数据也是错误的洛? |
-- 作者:jinzhe -- 发布时间:2016/6/17 14:32:08 -- 何以见得? |
-- 作者:我不是新手 -- 发布时间:2016/6/17 15:02:29 -- 图标交易想用的是最新价下单、但是测评的时候不都是按照收盘价来计算吗? |
-- 作者:jinzhe -- 发布时间:2016/6/17 15:06:28 -- 你用走完k线下单模式就是一样的了 测评是按照走完k线下单来算的 用户想要即时触发下单不是测评的交易方式 [此贴子已经被作者于2016-6-17 15:06:34编辑过]
|