-
-
Notifications
You must be signed in to change notification settings - Fork 4
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
Refactor fill time periods function #25
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we use:
start_dts = pd.to_datetime(time_periods["start_dt"]).ceil(freq)
end_dts = pd.to_datetime(time_periods['end_dt'])
?
So that won't work for the start_dts but yeah that's a nicer way to do the end_dts, will change that now |
Oh okay, why won't it work for the start_dts? I ran:
Am I missing something? |
147d6d7
to
bded8db
Compare
I was missing a .values! Works now |
Cool! Nice work. Sorry to nitpick but to keep it cleaner can we add |
Pull Request
Description
Small refactor of
fill_time_periods
to remove usingiterrows()
to hopefully make it more efficientHow Has This Been Tested?
A unit test already existed for this which is great so just checked that still passes