Modify ↓
Opened 5 years ago
Closed 5 years ago
#13605 closed enhancement (fixed)
Add configuration parameter for count of words
Reported by: | Massimo | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | LoomingCloudsPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 1.2 |
Attachments (1)
Change History (6)
Changed 5 years ago by
Attachment: | Screenshot_2019-09-05_08-06-06.png added |
---|
comment:4 Changed 5 years ago by
You can limit using two values:
[loomingclouds] min_count = 2 max_keywords = 10
The example will display only keywords with a count of 2+, up to a maximum of 10 keywords.
Counter.most_common(n)
seems to return arbitrary values in the case that there are a number of equal values > n. Example:
>>> from collections import Counter >>> c = Counter(dict([('a', 2), ('b', 2), ('c', 2), ('d', 1)])) >>> c Counter({'a': 2, 'c': 2, 'b': 2, 'd': 1}) >>> c.most_common(2) [('a', 2), ('c', 2)] >>> c.most_common(3) [('a', 2), ('c', 2), ('b', 2)]
The min_count
option will give more predicable results.
comment:5 Changed 5 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note: See
TracTickets for help on using
tickets.
Keywords with LoomingCloudsPlugin