Skip to content

Commit

Permalink
BUG: fixed swapped labels for beta_correlation action (#358)
Browse files Browse the repository at this point in the history
  • Loading branch information
cherman2 authored May 24, 2024
1 parent 1ebb1bf commit 50c486e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions q2_diversity/_beta/_beta_correlation.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
# ----------------------------------------------------------------------------


def beta_correlation(ctx, metadata, distance_matrix,
def beta_correlation(ctx, distance_matrix, metadata,
method="spearman", permutations=999,
intersect_ids=False, label1='Metadata',
label2='Distance Matrix'):
intersect_ids=False, label1='Distance Matrix',
label2='Metadata'):

convert_to_dist_matrix = ctx.get_action('metadata', 'distance_matrix')
mantel = ctx.get_action('diversity', 'mantel')
Expand Down
4 changes: 2 additions & 2 deletions q2_diversity/tests/test_beta_correlation.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ def setUp(self):

def test_execution(self):
# does it run?
self.beta_correlation(self.md, self.dm)
self.beta_correlation(self.dm, self.md)

def test_outputs(self):
result = self.beta_correlation(self.md, self.dm)
result = self.beta_correlation(self.dm, self.md)
# correct number of outputs?
self.assertEqual(2, len(result))
# correct types?
Expand Down

0 comments on commit 50c486e

Please sign in to comment.