Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

关于最近版本中的策略回测主力换月问题 #226

Open
RelentZ opened this issue Jan 6, 2024 · 1 comment
Open

关于最近版本中的策略回测主力换月问题 #226

RelentZ opened this issue Jan 6, 2024 · 1 comment

Comments

@RelentZ
Copy link

RelentZ commented Jan 6, 2024

我在windows平台上编译了C++版本的回测程序WtBtRunner.exe和样例中的策略WtCtaStraFact.dll,编译的commit为 [mod]修改了无数据时的长度标记,完善了逻辑,防止数据量超大出现的越界情况,导致反复解析
编译后,我按照文档进行了相关配置,配置文件发在了下方,回测数据使用的是dist目录下的storage和common文件夹,发现如果回测合约是主力合约,在主力合约换月之后就会一直读取换月之后合约名的csv文件,而storage下只有主力合约的csv文件。所以日志会不断地提示ERROR。
在运行dist里面的demo时,没有出现类似问题,请教下这种情况是我配置的不对,还是相比于dist里程序的版本,又有新增了功能,需要我做出更改?
附上策略的配置文件以及日志文件如下(配置文件上传不了yaml,我把yaml改成txt发上去了,实际程序读取的是yaml):
configbt.txt
Runner.log
Strategy_dt_if.log

@RelentZ RelentZ changed the title 关于样例中的策略回测问题 关于最近版本中的策略回测主力换月问题 Jan 6, 2024
@wondertrader
Copy link
Owner

根据我的理解,大概率是因为你回测的时间范围,超出了原来HOT文件的数据范围,所以才会去查找hots.json里对应的分月合约的数据

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants