About the setting of trunc_days
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 48.7k
- Forks
- 7.7k
- PR merge metrics
- No merged PRs in 30d
Description
In the document, the function of the parameter trunc_days is to avoid future information leakage:
"The trading days to be truncated the data in this segment may need ‘days’ data days are based on the test_start. For example, if the label contains the information of 2 days in the near future, the prediction horizon 1 day. (e.g. the prediction target is Ref($close, -2)/Ref($close, -1) - 1) the days should be 2 + 1 == 3 days."
I know what it means, but I still confused about why such process is necessary? If we don't truncate the days, when the segment is {"train": 2008/1/3-2008/1/29, "test":2008/1/30-2008/3/4}, why the information leakage happens?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the documentation that defines trunc_days and the train/test segment example, then trace how future-looking labels overlap the segment boundary. Clarify why the 2008/1/30 test start requires truncation and update the explanation so the leakage scenario and the expected day count are unambiguous.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- documentation, fintech-quant
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100