Skip to content

Panelnd #2242

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 4 commits into from
Dec 2, 2012
Merged

Panelnd #2242

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/core/api.py
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import numpy as np

from pandas.core.algorithms import factorize, match, unique, value_counts

from pandas.core.common import isnull, notnull, save, load
from pandas.core.categorical import Categorical, Factor
from pandas.core.format import (set_printoptions, reset_printoptions,
Expand All @@ -14,6 +13,7 @@
from pandas.core.series import Series, TimeSeries
from pandas.core.frame import DataFrame
from pandas.core.panel import Panel
from pandas.core.panel4d import Panel4D
from pandas.core.groupby import groupby
from pandas.core.reshape import (pivot_simple as pivot, get_dummies,
lreshape)
Expand Down
5 changes: 5 additions & 0 deletions pandas/core/indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,11 +240,16 @@ def _multi_take_opportunity(self, tup):
def _multi_take(self, tup):
from pandas.core.frame import DataFrame
from pandas.core.panel import Panel
from pandas.core.panel4d import Panel4D

if isinstance(self.obj, DataFrame):
index = self._convert_for_reindex(tup[0], axis=0)
columns = self._convert_for_reindex(tup[1], axis=1)
return self.obj.reindex(index=index, columns=columns)
elif isinstance(self.obj, Panel4D):
conv = [self._convert_for_reindex(x, axis=i)
for i, x in enumerate(tup)]
return self.obj.reindex(labels=tup[0],items=tup[1], major=tup[2], minor=tup[3])
elif isinstance(self.obj, Panel):
conv = [self._convert_for_reindex(x, axis=i)
for i, x in enumerate(tup)]
Expand Down
Loading