Repository navigation
择时逐资产、现金与模型成本的可核验收益归因 - #9
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
择时原生账本原先只保留汇总收益,导出时将基础成本和非线性冲击一起记入slippage。现在直接保留原计算路径的资产、现金、保证金、期货盈亏及两项成本,按期初净资产连接为可加总贡献,并单列market_impact,总成本和原收益不变。
新增描述性全区间与每个原生测试折的归因、逐日CSV及标准清单绑定;按决策日和次日收益计分,各折独立归因但不重新执行账户,不聚合重叠折。原生核验重算贡献、持仓收益权重、费用金额及汇总;缺失、损坏和账本不一致均拒绝。旧产物保持兼容,不补写或声称真实滑点与因果识别。
验证:128项测试、Ruff检查通过;4组Studio原生CLI集成通过。合成、真实四ETF和现金/期货/冲击组合的原收益、交易路径与分折保持一致;既有12组历史研究、120折完成归因,原5类收益指标保持一致,91份来源文件哈希和修改时间不变。未增加前向样本。