Skip to content

Commit

Permalink
Fix selection of between strain cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
nickjcroucher committed Oct 8, 2024
1 parent 4d8f1b2 commit f166cfa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion PopPUNK/bgmm.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def findBetweenLabel_bgmm(means, assignments):
most_dists[mixture_component] = np.count_nonzero(assignments == mixture_component)

sorted_dists = sorted(most_dists.items(), key=operator.itemgetter(1), reverse=True)
return(sorted_dists[rank][0])
return(sorted_dists[0][0])

def findWithinLabel(means, assignments, rank = 0):
"""Identify within-strain links
Expand Down

0 comments on commit f166cfa

Please sign in to comment.