Skip to content

Commit efb18b6

Browse files
authored
Merge pull request #1434 from BlazZupan/kmeans-int-format
[FIX] KMeans: Silhouette score format precision fixed to integer
2 parents 7f464a6 + eb1555a commit efb18b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Orange/widgets/unsupervised/owkmeans.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ def show_results(self):
266266
score_span = (best_score - worst_score) or 1
267267
max_score = max(scores)
268268
nplaces = min(5, np.floor(abs(math.log(max(max_score, 1e-10)))) + 2)
269-
fmt = "{{:.{}f}}".format(nplaces)
269+
fmt = "{{:.{}f}}".format(int(nplaces))
270270
model = self.table_model
271271
model.setRowCount(len(k_scores))
272272
for i, (k, score) in enumerate(k_scores):

0 commit comments

Comments
 (0)