Skip to content

Commit

Permalink
REL: Iron out min dep. vsns + update to v0.1.0!
Browse files Browse the repository at this point in the history
(Removed reliance on numpy.testing.assert_array_equal().)

I've got minimum versions set where it seems necessary. This should be
suitable for releasing Qurro!
  • Loading branch information
fedarko committed Jun 24, 2019
1 parent 40bd679 commit e94c09b
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion qurro/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@
# The full license is in the file LICENSE.txt, distributed with this software.
# ----------------------------------------------------------------------------

__version__ = "0.0.0"
__version__ = "0.1.0"
name = "qurro"
15 changes: 7 additions & 8 deletions qurro/tests/test_filter_unextreme_features.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import biom
import numpy as np
from numpy.testing import assert_array_equal
from numpy import arange
from pandas import DataFrame
from pandas.testing import assert_frame_equal
import pytest
Expand All @@ -23,11 +22,11 @@ def get_test_data():
# Based on the BIOM docs' example of initialization using a np ndarray --
# http://biom-format.org/documentation/table_objects.html#examples
#
# np.arange(40) generates a numpy ndarray that just goes from 0 to 39 (i.e.
# arange(40) generates a numpy ndarray that just goes from 0 to 39 (i.e.
# contains 40 numbers). We reshape this ndarray to give it a sort of
# "tabular" structure (a 2-D array containing 8 arrays, each with 5
# numbers).
underlying_table_data = np.arange(40).reshape(8, 5)
underlying_table_data = arange(40).reshape(8, 5)
# Set the third sample in the data to contain all zeros, except for a
# count for F4 (so we can test what this function does with so-called
# "empty" samples after filtering out F4).
Expand Down Expand Up @@ -65,10 +64,10 @@ def test_filtering_basic():
assert sid in filtered_table.columns

# Check that the appropriate data is left in the table.
assert_array_equal(filtered_table.loc["F1"], [0, 1, 0, 3, 4])
assert_array_equal(filtered_table.loc["F2"], [5, 6, 0, 8, 9])
assert_array_equal(filtered_table.loc["F7"], [30, 31, 0, 33, 34])
assert_array_equal(filtered_table.loc["F8"], [35, 36, 0, 38, 39])
assert list(filtered_table.loc["F1"]) == [0, 1, 0, 3, 4]
assert list(filtered_table.loc["F2"]) == [5, 6, 0, 8, 9]
assert list(filtered_table.loc["F7"]) == [30, 31, 0, 33, 34]
assert list(filtered_table.loc["F8"]) == [35, 36, 0, 38, 39]

# Check that the rank filtering worked as expected.
expected_filtered_ranks = DataFrame(
Expand Down
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,11 @@
# for details.
include_package_data=True,
install_requires=[
"altair >= 3.0",
"altair >= 3.1.0",
"biom-format[hdf5]",
"click",
"numpy",
"pandas >= 0.20.0",
"numpy >= 1.12.0",
"pandas >= 0.20.1",
"scikit-bio > 0.5.3",
],
# Based on how Altair splits up its requirements:
Expand Down

0 comments on commit e94c09b

Please sign in to comment.