Commit f431b1c breaks using the indexes function on python lists

Issue #7 resolved
Zachary Hofmann created an issue

Commit f431b1c breaks using the indexes function on plain python lists

specifically this snippet from peak.py:

if np.issubdtype(y.dtype, np.unsignedinteger): raise ValueError("y must be signed")

which raises this error:

File "/usr/lib64/python3.5/site-packages/PeakUtils-1.0.1-py3.5.egg/peakutils/peak.py", line 32, in indexes AttributeError: 'list' object has no attribute 'dtype'

Comments (3)

  1. Lucas Hermann Negri repo owner

    Thanks. While I wasn't thinking in supporting lists (and the function doc did state that), adding an extra check made it work again with plain lists.

    Thanks again.

  2. Log in to comment