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

Enable ffill for datetimes #8981

Closed
wants to merge 1 commit into from
Closed

Conversation

max-sixty
Copy link
Collaborator

Notes inline. Would fix #4587

Notes inline. Would fix pydata#4587
@max-sixty
Copy link
Collaborator Author

Actually this is tougher than I realized. I'll close given this approach won't work. Open to ideas if anyone has a way of doing it...

@max-sixty max-sixty closed this Apr 28, 2024
@dcherian
Copy link
Contributor

Use .view(np.int64) instead?

@max-sixty
Copy link
Collaborator Author

Use .view(np.int64) instead?

But unfortunately np.int64 isn't nullable, so filling no longer makes sense...

@dcherian
Copy link
Contributor

NaT is np.iinfo.min() IIRC, so there's a path

>>> np.datetime64('nat').view(np.int64)
-9223372036854775808

@max-sixty
Copy link
Collaborator Author

Good point!

We would need to special-case that. Maybe a new numbagg routine... (though tbh I'm not sure how often folks are forward-filling datetimes. But would def accept a PR if someone wants to add...)

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.

ffill with datetime64 errors
2 participants