Skip to content

INT: Implement _set_freq for TDI/DTI #30495

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

Merged
merged 3 commits into from
Dec 27, 2019
Merged

Conversation

jbrockmendel
Copy link
Member

@jbrockmendel jbrockmendel commented Dec 26, 2019

@topper-123
Copy link
Contributor

topper-123 commented Dec 26, 2019

In #29604 I had to do the same methods twice for DateTimeIndex.difference and TimeDeltaIndex.difference, because PeriodIndex.difference worked differently.

Could you see if it works to add a difference method to this MixIn and remove the other two?

@topper-123 topper-123 added the Refactor Internal refactoring of code label Dec 26, 2019
@topper-123 topper-123 added this to the 1.0 milestone Dec 26, 2019
Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

@jbrockmendel
Copy link
Member Author

Could you see if it works to add a difference method to this MixIn and remove the other two?

Yes, in a follow-up I plan to see what else can be de-duplicated

@topper-123 topper-123 merged commit 2bd1c4c into pandas-dev:master Dec 27, 2019
@topper-123
Copy link
Contributor

Thanks, @jbrockmendel .

@jbrockmendel jbrockmendel deleted the closer branch December 27, 2019 16:17
AlexKirko pushed a commit to AlexKirko/pandas that referenced this pull request Dec 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Internal refactoring of code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

REF: internal method to set DatetimeIndex freq
3 participants