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

is _qtd bug ? #348

Open
wony-zheng opened this issue Apr 24, 2024 · 0 comments
Open

is _qtd bug ? #348

wony-zheng opened this issue Apr 24, 2024 · 0 comments

Comments

@wony-zheng
Copy link

def _qtd(df):
date = _dt.datetime.now()
for q in [1, 4, 7, 10]:
if date.month <= q:
return df[df.index >= _dt.datetime(date.year, q, 1).strftime("%Y-%m-01")]
return df[df.index >= date.strftime("%Y-%m-01")]

when today.month == 2 ,it loc df.index >= 'xxxx-04-01'

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

1 participant