Skip to content

Commit

Permalink
Fixed range handling of OSU dtypes
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Feb 19, 2018
1 parent d8a4da3 commit 92d9e35
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
3 changes: 2 additions & 1 deletion holoviews/core/data/interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,8 +287,9 @@ def range(cls, dataset, dimension):
return np.NaN, np.NaN
else:
try:
assert column.dtype.kind not in 'SUO'
return (np.nanmin(column), np.nanmax(column))
except TypeError:
except (AssertionError, TypeError):
column = [v for v in util.python2sort(column) if v is not None]
if not len(column):
return np.NaN, np.NaN
Expand Down
10 changes: 0 additions & 10 deletions holoviews/core/data/pandas.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,16 +294,6 @@ def dframe(cls, columns, dimensions):
return columns.data.copy()


@classmethod
def array(cls, dataset, dimensions):
if not dimensions:
dimensions = dataset.dimensions(label='name')
else:
dimensions = [dataset.get_dimensions(d).name for d in dimensions]
inds = [dataset.data.columns.index(dim.name) for dim in dimensions]
return dataset.data.values[:, inds]


@classmethod
def iloc(cls, dataset, index):
rows, cols = index
Expand Down

0 comments on commit 92d9e35

Please sign in to comment.