Skip to content

更新数据截止到上一交易日#194

Open
imbian wants to merge 1 commit intorefraction-ray:masterfrom
imbian:master
Open

更新数据截止到上一交易日#194
imbian wants to merge 1 commit intorefraction-ray:masterfrom
imbian:master

Conversation

@imbian
Copy link

@imbian imbian commented Apr 25, 2025

更新数据截止到上一交易日,如周一获取昨日数据会一直在线更新。

@refraction-ray
Copy link
Owner

refraction-ray commented Apr 25, 2025

非常感谢贡献,很好的想法,但是用 last_onday 有一个小问题,这个函数会找到上一个国内交易日,但 universal 里的通用日线逻辑可能会处理其他交易市场的标的(比如他们十一并不休息,应该有数据更新)。
修改建议,使用上一个工作日的函数(https://pandas.pydata.org/docs/reference/api/pandas.tseries.offsets.BusinessDay.html#pandas.tseries.offsets.BusinessDay) ,只简单排除周六日,而不对其他的可能节假日进行排除,防止漏掉可能的交易日数据。

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

Successfully merging this pull request may close these issues.

2 participants