Skip to content

Commit

Permalink
CLN: remove unused get methods in internals (pandas-dev#17169)
Browse files Browse the repository at this point in the history
* Remove unused get methods that would raise AttributeError if called

* Remove unnecessary import
  • Loading branch information
jbrockmendel authored and alanbato committed Nov 10, 2017
1 parent 3c126f5 commit 68d07bf
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions pandas/core/internals.py
Original file line number Diff line number Diff line change
Expand Up @@ -327,10 +327,6 @@ def reindex_axis(self, indexer, method=None, axis=1, fill_value=None,
fill_value=fill_value, mask_info=mask_info)
return self.make_block(new_values, fastpath=True)

def get(self, item):
loc = self.items.get_loc(item)
return self.values[loc]

def iget(self, i):
return self.values[i]

Expand Down Expand Up @@ -1662,13 +1658,6 @@ def set(self, locs, values, check=False):
assert locs.tolist() == [0]
self.values = values

def get(self, item):
if self.ndim == 1:
loc = self.items.get_loc(item)
return self.values[loc]
else:
return self.values

def putmask(self, mask, new, align=True, inplace=False, axis=0,
transpose=False, mgr=None):
"""
Expand Down Expand Up @@ -4730,8 +4719,6 @@ def _concat_indexes(indexes):

def _block2d_to_blocknd(values, placement, shape, labels, ref_items):
""" pivot to the labels shape """
from pandas.core.internals import make_block

panel_shape = (len(placement),) + shape

# TODO: lexsort depth needs to be 2!!
Expand Down

0 comments on commit 68d07bf

Please sign in to comment.