Skip to content

Commit

Permalink
Merge pull request #33 from biocore/fix_eigen_order
Browse files Browse the repository at this point in the history
fix eigenvalues order issue
  • Loading branch information
mortonjt committed Apr 16, 2019
2 parents 41278a3 + 5325a45 commit eb392a4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# DEICODE changelog

## Version 0.2.1 (2019-4-15)

Implemented in [PR#33](https://github.com/biocore/DEICODE/pull/33).

### Bug fixes

* Eigenvalues were out of order, single line problem in optspace.py

## Version 0.2.0 (2019-4-8)

Implemented in [PR#29](https://github.com/biocore/DEICODE/pull/29).
Expand Down
2 changes: 1 addition & 1 deletion deicode/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
#
# ----------------------------------------------------------------------------

__version__ = "0.2.0"
__version__ = "0.2.1"
2 changes: 1 addition & 1 deletion deicode/optspace.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def _fit(self):
niter=self.iteration, tol=self.tol)
solution = U.dot(s_).dot(V.T)
explained_variance_ratio_ = np.diag(s_) / np.diag(s_).sum()
self.eigenvalues = np.diag(s_)
self.eigenvalues = np.diag(s_)[::-1]
self.explained_variance_ratio = list(explained_variance_ratio_)[::-1]
self.distance = distance.cdist(U, U)
self.solution = solution
Expand Down

0 comments on commit eb392a4

Please sign in to comment.