Comments (4)
目前股票的撮合逻辑是用的当天收盘价。说到底,在当前bar既做策略逻辑的生成,又用于成交,多少都会有点”使用未来数据“的问题。只不过股票有T+1的限制,所以使用当前bar进行成交没有那么大影响罢了。您所说使用当天开盘价进行撮合成交,在我看来其实与使用当天收盘价,或者平均成交价,区别不太大——都是当天的bar数据嘛。如果非要说调整的话,那可能也是用当天bar做策略逻辑生成,使用下一个bar的开盘价(或其他价格)做撮合成交。您觉得呢?
from rqalpha.
我觉得可以按照zipline的思路 当个bar出信号 下个bar以开盘价成交,这样比较符合实际
from rqalpha.
@shaoshoutianheyu 我们最近的更新会提供用类似zipline的方法的另外一种撮合,以后会以这种撮合为主。发布了以后再close这个case。
from rqalpha.
@jaskell 其实每个人回测都有自己的业务场景,在自己的业务场景中合理,可能对于别人来说并不合理。
所以新版本的RQAlpha提供了两种撮合方式,以当前Bar的Close价格进行撮合,或者以下一个Bar的Open价格来撮合,您可以直接通过配置的方式来选择自己需要的撮合方式。具体参考 参数配置
如果这两种撮合方式也不能满足您的需求,您也可以 通过 扩展 Mod 的方式 自己写一个撮合引擎扩展(AbstractMatcher) 来自定义撮合逻辑。
from rqalpha.
Related Issues (20)
- 问题:分钟级回测时,订单有没有可能在多个分钟线撮合成交 HOT 1
- 请问scheduler.run_daily是不是不适用于tick级回测? HOT 1
- tick级回测时,限价单剩余数量会继续在后面的tick上成交吗? HOT 1
- 按照教程里面的mod安装失败. enable找不到 HOT 3
- 能否开源增量回测功能呀?? HOT 1
- bug: 订单被拒单: [RR2309] 当前缺失市场数据。订单被拒时间有误 HOT 3
- 数据错误,停牌期间数据发生变化 HOT 2
- 为什么instrument设计order_book_id 和 trading_code, ctp交易的时候 order_book_id 和交易所代码不一致,无法subscribe HOT 1
- open_auction中发布的股票卖单,非一字跌停时,被拒单。 HOT 2
- 集合竞价发限价单,可以加滑点吗?
- 如何启用融资功能? HOT 1
- futures.get_dominant_price接口特性需求 HOT 2
- 1分钟线期货回测出错 HOT 2
- open_auction()中发出的买单经常会以低于开盘价成交,有时则不会。 HOT 1
- 分钟线回测,下个bar内部满足条件未成交 HOT 6
- [FEATURE] 限价(LIMIT_ORDER)的交易逻辑问题 HOT 2
- QQ群加不了 HOT 2
- Matcher并没有真正地考虑算法单特定目标的执行情况? HOT 1
- 什么时候支持python3.12,3.12版本性能提升很大啊 HOT 4
- mac无法安装mod HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rqalpha.