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

BUG: Add frequency to DatetimeArray/TimedeltaArray take #58382

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

annika-rudolph
Copy link

@annika-rudolph annika-rudolph commented Apr 23, 2024

Disclaimer I am required to add that the software is provided "as is", without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose and noninfringement. In no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the software or the use or other dealings in the software.

@annika-rudolph annika-rudolph changed the title Add take function to Datetime and TimedeltaArray (GH 57949 and GH 58327) Add take function to Datetime and TimedeltaArray Apr 23, 2024
@annika-rudolph annika-rudolph force-pushed the fix_get_level_values_gh_58327 branch 2 times, most recently from 19d396d to 5440815 Compare April 25, 2024 08:22
@annika-rudolph annika-rudolph changed the title Add take function to Datetime and TimedeltaArray BUG: Add frequency to DatetimeIndex/TimedeltaIndex shallow copy Apr 25, 2024
@annika-rudolph annika-rudolph changed the title BUG: Add frequency to DatetimeIndex/TimedeltaIndex shallow copy BUG: Add frequency to DatetimeIndex/TimedeltaIndex _shallow_copy Apr 25, 2024
@annika-rudolph annika-rudolph marked this pull request as ready for review April 25, 2024 12:22
@@ -1244,7 +1244,9 @@ def _constructor(self) -> Callable[..., MultiIndex]: # type: ignore[override]
return type(self).from_tuples

@doc(Index._shallow_copy)
def _shallow_copy(self, values: np.ndarray, name=lib.no_default) -> MultiIndex:
def _shallow_copy(
Copy link
Member

Choose a reason for hiding this comment

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

if the options are doing this in take or shallow_copy, take is definitely preferred

Copy link
Author

Choose a reason for hiding this comment

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

done -- implemented via take

@annika-rudolph annika-rudolph changed the title BUG: Add frequency to DatetimeIndex/TimedeltaIndex _shallow_copy BUG: Add frequency to DatetimeArray/TimedeltaArray take Apr 30, 2024
@annika-rudolph annika-rudolph force-pushed the fix_get_level_values_gh_58327 branch from 90a5c3f to cae8e63 Compare May 2, 2024 07:04
@annika-rudolph annika-rudolph force-pushed the fix_get_level_values_gh_58327 branch from cae8e63 to ceb3633 Compare May 3, 2024 07:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants